diff options
| author | Teddy Wing | 2019-05-01 15:14:37 +0200 |
|---|---|---|
| committer | Teddy Wing | 2019-05-01 15:14:37 +0200 |
| commit | 33f83a17badb4586c0eb0e3b78aef9c8debe371f (patch) | |
| tree | 1c7cd2c9605301ff38df1842ac1e5fd51ad81fb4 | |
| parent | 10fa99186f46435c179ec6cfdbe2407f5a04f7a4 (diff) | |
| download | muttagen-33f83a17badb4586c0eb0e3b78aef9c8debe371f.tar.bz2 | |
Move code to "style.ts"
* Create a separate module for the CSS style-related code.
* Use `commonjs` module format instead of `amd` so that the resulting
output file can be used (hopefully) without modification directly in
the browser.
| -rw-r--r-- | src/index.ts | 8 | ||||
| -rw-r--r-- | src/style.ts (renamed from index.ts) | 7 | ||||
| -rw-r--r-- | tsconfig.json | 6 |
3 files changed, 11 insertions, 10 deletions
diff --git a/src/index.ts b/src/index.ts new file mode 100644 index 0000000..e5c3103 --- /dev/null +++ b/src/index.ts @@ -0,0 +1,8 @@ +// ==UserScript== +// @name Muttagen +// @description Gmail user script providing Mutt features +// @namespace com.teddywing +// @match https://mail.google.com/* +// ==/UserScript== + +import "./style.ts"; @@ -1,10 +1,3 @@ -// ==UserScript== -// @name Muttagen -// @description Gmail user script providing Mutt features -// @namespace com.teddywing -// @match https://mail.google.com/* -// ==/UserScript== - type GmailCSSClass = string; const TOOLS_PANEL: GmailCSSClass = 'bAw'; diff --git a/tsconfig.json b/tsconfig.json index f6b7f29..1c994f4 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,11 +1,11 @@ { "compilerOptions": { - "module": "amd", + "module": "commonjs", "target": "ES5", "outFile": "./build/muttagen.user.js", "sourceMap": true }, - "files": [ - "index.ts" + "include": [ + "src/**/*" ] } |
