JSPM

rollup-plugin-userscript-css

1.2.0
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 5
  • Score
    100M100P100Q30152F
  • License MIT

import css file for userscirpt

Package Exports

  • rollup-plugin-userscript-css

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (rollup-plugin-userscript-css) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

Rollup UserScript Css Plugin

This Rollup plugin will import css file for Greasemonkey / Tampermonkey.

Install

npm install --save rollup-plugin-userscript-css

usage

import './test.css'

rollup.config.js

import userScriptCss from 'rollup-plugin-userscript-css'

export default {
  ...
  plugins: [
    userScriptCss()
  ]
}

Options

insert

  • Default: true
  • Type: Boolean

Default true, the plugin will insert CSS into <head/> tag.

include

  • Default: [ '**/*.css' ]

  • Type: String|Array

Minimatch pattern or array of minimatch patterns to determine which files are transpiled by the plugin.

exclude

  • Default: node_modules/**

  • Type: String|Array

Minimatch pattern or array of minimatch patterns to determine which files are explicitly not transpiled by the plugin, overrules the include option.

References