ScoreSaberUtils-Script/webpack.config.js
Liam 11ae94dc3e
All checks were successful
Deploy App / docker (ubuntu-latest) (push) Successful in 31s
add file headers that were missing and add a readme
2024-04-25 23:51:36 +01:00

37 lines
906 B
JavaScript

const path = require('path');
const { UserscriptPlugin } = require('webpack-userscript');
module.exports = {
entry: './src/index.ts',
mode: 'production',
module: {
rules: [
{
test: /\.tsx?$/,
use: 'ts-loader',
exclude: /node_modules/,
},
],
},
resolve: {
extensions: ['.tsx', '.ts', '.js'],
},
plugins: [
new UserscriptPlugin({
headers: {
name: "ScoreSaber Utils",
"run-at": "document-end",
match: "https://scoresaber.com/*",
updateURL: "https://ssu.fascinated.cc/scripts/bundle.user.js",
downloadURL: "https://ssu.fascinated.cc/scripts/bundle.user.js",
require: ["https://ssu.fascinated.cc/scripts/bundle.meta.js"],
version: `1.0.0-${process.env.GIT_REV || 'dev'}`,
}
})
],
output: {
filename: 'bundle.js',
path: path.resolve(__dirname, 'dist'),
},
};