Skip to content

wdssmq/userscript

Repository files navigation

概述

各种猴子脚本

关于

博客:https://www.wdssmq.com

爱发电: https://afdian.com/@wdssmq

更多脚本: https://github.com/wdssmq/userscript

GreasyFork: https://greasyfork.org/zh-CN/users/6865

交流反馈:189574683

wdssmq/rollup-plugin-monkey: 使用 rollup 开发「GM_脚本」:

https://github.com/wdssmq/rollup-plugin-monkey

已有项目

占位

up empty_def

PROJECT_SCRIPT=empty_def
rm -rf ${PROJECT_SCRIPT}
# 下载初始模板
wget https://ghproxy.com/https://github.com/wdssmq/rollup-plugin-monkey/releases/latest/download/script_def.tar.gz
tar -xzvf script_def.tar.gz
mv script_def ${PROJECT_SCRIPT}
# cd ${PROJECT_SCRIPT}
sed -i "s/\"script_def\"/\"${PROJECT_SCRIPT}\"/" ${PROJECT_SCRIPT}/src/__info.js
eslint empty_def/**/*.js empty_def/*.mjs --fix
rm -rf script_def.tar.gz

postcss

cnpm i postcss rollup-plugin-postcss -d
# less sass stylus 按需安装对应的依赖
import postcss from "rollup-plugin-postcss";

[prodConfig, devConfig].forEach((config) => {
  config.plugins.push(postcss());
});