https://github.com/violentmonkey/generator-userscript
A yeoman generator to create a userscript project rapidly
https://github.com/violentmonkey/generator-userscript
Last synced: 11 months ago
JSON representation
A yeoman generator to create a userscript project rapidly
- Host: GitHub
- URL: https://github.com/violentmonkey/generator-userscript
- Owner: violentmonkey
- Created: 2020-03-08T10:14:46.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2025-04-01T01:49:40.000Z (11 months ago)
- Last Synced: 2025-04-01T02:35:27.934Z (11 months ago)
- Language: JavaScript
- Size: 121 KB
- Stars: 113
- Watchers: 3
- Forks: 8
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# @violentmonkey/generator-userscript

Yeoman generator to create a workspace for userscript easily.
## Prerequisites
- Node.js >= 18
## Features
- TypeScript
- [SolidJS](https://www.solidjs.com/)
- CSS modules (applied for `.module.css` files)
- [UnoCSS](https://unocss.dev/)
Read [this](https://violentmonkey.github.io/guide/using-modern-syntax/) for more details.
## Get Started
First of all, make a new directory for your userscript.
```sh
$ mkdir my-script
$ cd my-script
```
Then follow one of the options below to create the files.
### Option 1: npm
Please make sure your `npm` is up to date because in earlier versions (e.g. 8.12.x) there was a bug that prevented `npx` from installing the correct dependencies.
```bash
$ npm i npm -g
# Use the latest version from git
$ npx -p github:violentmonkey/generator-userscript -p yo yo @violentmonkey/userscript
```
### Option 2: pnpm
```bash
$ pnpm --package github:violentmonkey/generator-userscript --package yo dlx yo @violentmonkey/userscript
```