@w5s/commitlint-config 3.0.6 → 3.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/index.d.ts +17 -8
- package/dist/index.js +82 -49
- package/dist/index.js.map +1 -1
- package/package.json +6 -29
- package/src/config.ts +34 -0
- package/src/index.ts +2 -36
- package/src/meta.ts +8 -0
package/README.md
CHANGED
|
@@ -38,7 +38,7 @@ Extra rules
|
|
|
38
38
|
"commitlint": {
|
|
39
39
|
"rules": {
|
|
40
40
|
// Rule to validate gitmoji unicode (🐛) or emoji (:bug:)
|
|
41
|
-
"type-gitmoji-style": ["error", "always", "unicode"
|
|
41
|
+
"type-gitmoji-style": ["error", "always", "unicode"],
|
|
42
42
|
// Rule to validate a gitmoji in the list
|
|
43
43
|
"type-valid-gitmoji": ["error", "always"]
|
|
44
44
|
}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,11 +1,20 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as _commitlint_types0 from "@commitlint/types";
|
|
2
2
|
|
|
3
|
+
//#region src/meta.d.ts
|
|
4
|
+
declare const meta: Readonly<{
|
|
5
|
+
name: string;
|
|
6
|
+
version: string;
|
|
7
|
+
buildNumber: number;
|
|
8
|
+
}>;
|
|
9
|
+
//#endregion
|
|
10
|
+
//#region src/config.d.ts
|
|
3
11
|
declare const config: {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
12
|
+
parserPreset: {
|
|
13
|
+
parserOpts: any;
|
|
14
|
+
};
|
|
15
|
+
rules: Partial<_commitlint_types0.RulesConfig<_commitlint_types0.RuleConfigQuality.Qualified>>;
|
|
16
|
+
plugins: _commitlint_types0.Plugin[];
|
|
9
17
|
};
|
|
10
|
-
|
|
11
|
-
export { config as default };
|
|
18
|
+
//#endregion
|
|
19
|
+
export { config as default, meta };
|
|
20
|
+
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.js
CHANGED
|
@@ -1,54 +1,87 @@
|
|
|
1
|
-
import { RuleConfigSeverity } from
|
|
2
|
-
import conventionalChangelogPreset, { Emoji, GitmojiCode } from
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
rules: {
|
|
17
|
-
"type-gitmoji-style": typeGitmojiStyle,
|
|
18
|
-
"type-valid-gitmoji": typeValidGitmoji
|
|
19
|
-
}
|
|
20
|
-
};
|
|
21
|
-
|
|
22
|
-
// src/index.ts
|
|
23
|
-
var { Error, Warning, Disabled } = RuleConfigSeverity;
|
|
24
|
-
var parserPreset = {
|
|
25
|
-
// eslint-disable-next-line unicorn/no-await-expression-member
|
|
26
|
-
parserOpts: (await conventionalChangelogPreset()).parser
|
|
1
|
+
import { RuleConfigSeverity } from "@commitlint/types";
|
|
2
|
+
import conventionalChangelogPreset, { Emoji, GitmojiCode } from "@w5s/conventional-changelog";
|
|
3
|
+
//#region src/meta.ts
|
|
4
|
+
const meta = Object.freeze({
|
|
5
|
+
name: "@w5s/commitlint-config",
|
|
6
|
+
version: "3.1.0",
|
|
7
|
+
buildNumber: 1
|
|
8
|
+
});
|
|
9
|
+
//#endregion
|
|
10
|
+
//#region src/plugin.ts
|
|
11
|
+
const $if = (when = "always") => (cond) => when === "always" ? cond : !cond;
|
|
12
|
+
const typeGitmojiStyle = (parsed, when = "always", value = "unicode") => {
|
|
13
|
+
const isUnicode = parsed.type != null && Emoji.isUnicode(parsed.type);
|
|
14
|
+
const isEmoji = parsed.type != null && Emoji.isText(parsed.type);
|
|
15
|
+
return value === "unicode" ? $if(when)(isUnicode) ? [true] : [false, `Type should ${when} be an unicode character`] : $if(when)(isEmoji) ? [true] : [false, `Type should ${when} be an valid :emoji:`];
|
|
27
16
|
};
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
"footer-leading-blank": [Warning, "always"],
|
|
32
|
-
"footer-max-line-length": [Error, "always", 100],
|
|
33
|
-
"header-max-length": [Error, "always", 100],
|
|
34
|
-
"scope-case": [Error, "always", "lower-case"],
|
|
35
|
-
"subject-case": [Error, "always", ["sentence-case"]],
|
|
36
|
-
"subject-empty": [Error, "never"],
|
|
37
|
-
"subject-exclamation-mark": [Error, "never"],
|
|
38
|
-
"subject-full-stop": [Error, "never", "."],
|
|
39
|
-
"type-case": [Error, "always", "lower-case"],
|
|
40
|
-
"type-empty": [Error, "never"],
|
|
41
|
-
"type-enum": [Disabled],
|
|
42
|
-
"type-gitmoji-style": [Error, "always", "unicode"],
|
|
43
|
-
"type-valid-gitmoji": [Error, "always"]
|
|
17
|
+
const typeValidGitmoji = (parsed, when = "always") => {
|
|
18
|
+
const isValidGitmoji = parsed.type != null && GitmojiCode.isValid(parsed.type);
|
|
19
|
+
return $if(when)(isValidGitmoji) ? [true] : [false, `Type should ${when} be an valid gitmoji (see https://gitmoji.dev)`];
|
|
44
20
|
};
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
21
|
+
/**
|
|
22
|
+
* Gitmoji plugins
|
|
23
|
+
*/
|
|
24
|
+
const gitmojiPlugin = { rules: {
|
|
25
|
+
"type-gitmoji-style": typeGitmojiStyle,
|
|
26
|
+
"type-valid-gitmoji": typeValidGitmoji
|
|
27
|
+
} };
|
|
28
|
+
//#endregion
|
|
29
|
+
//#region src/config.ts
|
|
30
|
+
const { Error, Warning, Disabled } = RuleConfigSeverity;
|
|
31
|
+
const config = {
|
|
32
|
+
parserPreset: { parserOpts: (await conventionalChangelogPreset()).parser },
|
|
33
|
+
rules: {
|
|
34
|
+
"body-leading-blank": [Warning, "always"],
|
|
35
|
+
"body-max-line-length": [
|
|
36
|
+
Error,
|
|
37
|
+
"always",
|
|
38
|
+
100
|
|
39
|
+
],
|
|
40
|
+
"footer-leading-blank": [Warning, "always"],
|
|
41
|
+
"footer-max-line-length": [
|
|
42
|
+
Error,
|
|
43
|
+
"always",
|
|
44
|
+
100
|
|
45
|
+
],
|
|
46
|
+
"header-max-length": [
|
|
47
|
+
Error,
|
|
48
|
+
"always",
|
|
49
|
+
100
|
|
50
|
+
],
|
|
51
|
+
"scope-case": [
|
|
52
|
+
Error,
|
|
53
|
+
"always",
|
|
54
|
+
"lower-case"
|
|
55
|
+
],
|
|
56
|
+
"subject-case": [
|
|
57
|
+
Error,
|
|
58
|
+
"always",
|
|
59
|
+
["sentence-case"]
|
|
60
|
+
],
|
|
61
|
+
"subject-empty": [Error, "never"],
|
|
62
|
+
"subject-exclamation-mark": [Error, "never"],
|
|
63
|
+
"subject-full-stop": [
|
|
64
|
+
Error,
|
|
65
|
+
"never",
|
|
66
|
+
"."
|
|
67
|
+
],
|
|
68
|
+
"type-case": [
|
|
69
|
+
Error,
|
|
70
|
+
"always",
|
|
71
|
+
"lower-case"
|
|
72
|
+
],
|
|
73
|
+
"type-empty": [Error, "never"],
|
|
74
|
+
"type-enum": [Disabled],
|
|
75
|
+
"type-gitmoji-style": [
|
|
76
|
+
Error,
|
|
77
|
+
"always",
|
|
78
|
+
"unicode"
|
|
79
|
+
],
|
|
80
|
+
"type-valid-gitmoji": [Error, "always"]
|
|
81
|
+
},
|
|
82
|
+
plugins: [gitmojiPlugin]
|
|
49
83
|
};
|
|
50
|
-
|
|
84
|
+
//#endregion
|
|
85
|
+
export { config as default, meta };
|
|
51
86
|
|
|
52
|
-
export { index_default as default };
|
|
53
|
-
//# sourceMappingURL=index.js.map
|
|
54
87
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/plugin.ts","../src/
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../src/meta.ts","../src/plugin.ts","../src/config.ts"],"sourcesContent":["export const meta = Object.freeze({\n // @ts-ignore - these variables are injected at build time\n name: (typeof __PACKAGE_NAME__ === 'undefined' ? '' : __PACKAGE_NAME__) as string,\n // @ts-ignore - these variables are injected at build time\n version: (typeof __PACKAGE_VERSION__ === 'undefined' ? '' : __PACKAGE_VERSION__) as string,\n // @ts-ignore - these variables are injected at build time\n buildNumber: 1 as number, // (typeof __PACKAGE_BUILD_NUMBER__ === 'undefined' ? 0 : __PACKAGE_BUILD_NUMBER__) as number,\n});\n","import type { Plugin, Rule, RuleConfigCondition } from '@commitlint/types';\nimport { Emoji, GitmojiCode } from '@w5s/conventional-changelog';\n\nconst $if =\n (when: RuleConfigCondition | undefined = 'always') =>\n (cond: boolean) =>\n when === 'always' ? cond : !cond;\n\nexport const typeGitmojiStyle: Rule<'unicode' | 'emoji'> = (parsed, when = 'always', value = 'unicode') => {\n const isUnicode = parsed.type != null && Emoji.isUnicode(parsed.type);\n const isEmoji = parsed.type != null && Emoji.isText(parsed.type);\n\n return value === 'unicode'\n ? $if(when)(isUnicode)\n ? [true]\n : [false, `Type should ${when} be an unicode character`]\n : $if(when)(isEmoji)\n ? [true]\n : [false, `Type should ${when} be an valid :emoji:`];\n};\n\nexport const typeValidGitmoji: Rule = (parsed, when = 'always') => {\n const isValidGitmoji = parsed.type != null && GitmojiCode.isValid(parsed.type);\n\n return $if(when)(isValidGitmoji)\n ? [true]\n : [false, `Type should ${when} be an valid gitmoji (see https://gitmoji.dev)`];\n};\n\n/**\n * Gitmoji plugins\n */\nexport const gitmojiPlugin: Plugin = {\n rules: {\n 'type-gitmoji-style': typeGitmojiStyle,\n 'type-valid-gitmoji': typeValidGitmoji,\n },\n};\n","import { RuleConfigSeverity, type QualifiedRules, type LintOptions } from '@commitlint/types';\nimport conventionalChangelogPreset from '@w5s/conventional-changelog';\nimport { gitmojiPlugin } from './plugin.js';\n\nconst { Error, Warning, Disabled } = RuleConfigSeverity;\n\nconst parserPreset = {\n // eslint-disable-next-line unicorn/no-await-expression-member\n parserOpts: (await conventionalChangelogPreset()).parser as any,\n} satisfies LintOptions;\n\nconst rules: QualifiedRules = {\n 'body-leading-blank': [Warning, 'always'],\n 'body-max-line-length': [Error, 'always', 100],\n 'footer-leading-blank': [Warning, 'always'],\n 'footer-max-line-length': [Error, 'always', 100],\n 'header-max-length': [Error, 'always', 100],\n 'scope-case': [Error, 'always', 'lower-case'],\n 'subject-case': [Error, 'always', ['sentence-case']],\n 'subject-empty': [Error, 'never'],\n 'subject-exclamation-mark': [Error, 'never'],\n 'subject-full-stop': [Error, 'never', '.'],\n 'type-case': [Error, 'always', 'lower-case'],\n 'type-empty': [Error, 'never'],\n 'type-enum': [Disabled],\n 'type-gitmoji-style': [Error, 'always', 'unicode'],\n 'type-valid-gitmoji': [Error, 'always'],\n};\n\nexport const config = {\n parserPreset,\n rules,\n plugins: [gitmojiPlugin],\n};\n"],"mappings":";;;AAAA,MAAa,OAAO,OAAO,OAAO;CAEhC,MAAA;CAEA,SAAA;CAEA,aAAa;CACd,CAAC;;;ACJF,MAAM,OACH,OAAwC,cACtC,SACC,SAAS,WAAW,OAAO,CAAC;AAElC,MAAa,oBAA+C,QAAQ,OAAO,UAAU,QAAQ,cAAc;CACzG,MAAM,YAAY,OAAO,QAAQ,QAAQ,MAAM,UAAU,OAAO,KAAK;CACrE,MAAM,UAAU,OAAO,QAAQ,QAAQ,MAAM,OAAO,OAAO,KAAK;AAEhE,QAAO,UAAU,YACb,IAAI,KAAK,CAAC,UAAU,GAClB,CAAC,KAAK,GACN,CAAC,OAAO,eAAe,KAAK,0BAA0B,GACxD,IAAI,KAAK,CAAC,QAAQ,GAChB,CAAC,KAAK,GACN,CAAC,OAAO,eAAe,KAAK,sBAAsB;;AAG1D,MAAa,oBAA0B,QAAQ,OAAO,aAAa;CACjE,MAAM,iBAAiB,OAAO,QAAQ,QAAQ,YAAY,QAAQ,OAAO,KAAK;AAE9E,QAAO,IAAI,KAAK,CAAC,eAAe,GAC5B,CAAC,KAAK,GACN,CAAC,OAAO,eAAe,KAAK,gDAAgD;;;;;AAMlF,MAAa,gBAAwB,EACnC,OAAO;CACL,sBAAsB;CACtB,sBAAsB;CACvB,EACF;;;ACjCD,MAAM,EAAE,OAAO,SAAS,aAAa;AAyBrC,MAAa,SAAS;CACpB,cAxBmB,EAEnB,aAAa,MAAM,6BAA6B,EAAE,QACnD;CAsBC,OApB4B;EAC5B,sBAAsB,CAAC,SAAS,SAAS;EACzC,wBAAwB;GAAC;GAAO;GAAU;GAAI;EAC9C,wBAAwB,CAAC,SAAS,SAAS;EAC3C,0BAA0B;GAAC;GAAO;GAAU;GAAI;EAChD,qBAAqB;GAAC;GAAO;GAAU;GAAI;EAC3C,cAAc;GAAC;GAAO;GAAU;GAAa;EAC7C,gBAAgB;GAAC;GAAO;GAAU,CAAC,gBAAgB;GAAC;EACpD,iBAAiB,CAAC,OAAO,QAAQ;EACjC,4BAA4B,CAAC,OAAO,QAAQ;EAC5C,qBAAqB;GAAC;GAAO;GAAS;GAAI;EAC1C,aAAa;GAAC;GAAO;GAAU;GAAa;EAC5C,cAAc,CAAC,OAAO,QAAQ;EAC9B,aAAa,CAAC,SAAS;EACvB,sBAAsB;GAAC;GAAO;GAAU;GAAU;EAClD,sBAAsB,CAAC,OAAO,SAAS;EACxC;CAKC,SAAS,CAAC,cAAc;CACzB"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@w5s/commitlint-config",
|
|
3
|
-
"version": "3.0
|
|
3
|
+
"version": "3.1.0",
|
|
4
4
|
"description": "Commitlint configuration presets",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"commitlint",
|
|
@@ -28,44 +28,22 @@
|
|
|
28
28
|
},
|
|
29
29
|
"./dist/*": "./dist/*"
|
|
30
30
|
},
|
|
31
|
-
"typings": "./index.d.
|
|
31
|
+
"typings": "./index.d.mts",
|
|
32
32
|
"files": [
|
|
33
33
|
"dist/",
|
|
34
34
|
"src/",
|
|
35
35
|
"index.js",
|
|
36
36
|
"index.d.ts",
|
|
37
|
-
"!*.d.
|
|
37
|
+
"!*.d.mts.map",
|
|
38
38
|
"!**/*.spec.*",
|
|
39
39
|
"!**/__tests__/**"
|
|
40
40
|
],
|
|
41
41
|
"scripts": {
|
|
42
|
-
"
|
|
43
|
-
"build:tsc": "npx tsup",
|
|
44
|
-
"clean": "npx run-p \"clean:*\"",
|
|
45
|
-
"clean:tsc": "rm -rf dist",
|
|
46
|
-
"docs": "node ../../markdown.mjs",
|
|
47
|
-
"format": "npx run-p \"format:*\"",
|
|
48
|
-
"format:src": "eslint . --fix",
|
|
49
|
-
"lint": "npx run-p \"lint:*\"",
|
|
50
|
-
"lint:src": "eslint .",
|
|
51
|
-
"postpack": "npx clean-package restore",
|
|
52
|
-
"prepack": "npx clean-package",
|
|
53
|
-
"prepare": "npx run-p \"prepare:*\"",
|
|
54
|
-
"prepare:empty": ":",
|
|
55
|
-
"prepublishOnly": "npm run clean;npm run build",
|
|
56
|
-
"spellcheck": "cspell --no-progress '**'",
|
|
57
|
-
"test": "npx run-p \"test:*\"",
|
|
58
|
-
"test:src": "vitest run"
|
|
42
|
+
"postpack": "clean-package restore"
|
|
59
43
|
},
|
|
60
44
|
"dependencies": {
|
|
61
45
|
"@commitlint/types": "^20.0.0",
|
|
62
|
-
"@w5s/conventional-changelog": "^3.0
|
|
63
|
-
},
|
|
64
|
-
"devDependencies": {
|
|
65
|
-
"@commitlint/lint": "20.4.2",
|
|
66
|
-
"@w5s/tsup-config": "2.0.4",
|
|
67
|
-
"vite": "7.3.1",
|
|
68
|
-
"vitest": "4.0.18"
|
|
46
|
+
"@w5s/conventional-changelog": "^3.1.0"
|
|
69
47
|
},
|
|
70
48
|
"peerDependencies": {
|
|
71
49
|
"@commitlint/cli": "^16.0.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^20.0.0"
|
|
@@ -75,7 +53,6 @@
|
|
|
75
53
|
"optional": true
|
|
76
54
|
}
|
|
77
55
|
},
|
|
78
|
-
"clean-package": "../../clean-package.config.mjs",
|
|
79
56
|
"engines": {
|
|
80
57
|
"node": ">=20.0.0"
|
|
81
58
|
},
|
|
@@ -83,5 +60,5 @@
|
|
|
83
60
|
"access": "public"
|
|
84
61
|
},
|
|
85
62
|
"sideEffect": false,
|
|
86
|
-
"gitHead": "
|
|
63
|
+
"gitHead": "8d96574cd89109fa8268a2c77601337ad871ef1e"
|
|
87
64
|
}
|
package/src/config.ts
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { RuleConfigSeverity, type QualifiedRules, type LintOptions } from '@commitlint/types';
|
|
2
|
+
import conventionalChangelogPreset from '@w5s/conventional-changelog';
|
|
3
|
+
import { gitmojiPlugin } from './plugin.js';
|
|
4
|
+
|
|
5
|
+
const { Error, Warning, Disabled } = RuleConfigSeverity;
|
|
6
|
+
|
|
7
|
+
const parserPreset = {
|
|
8
|
+
// eslint-disable-next-line unicorn/no-await-expression-member
|
|
9
|
+
parserOpts: (await conventionalChangelogPreset()).parser as any,
|
|
10
|
+
} satisfies LintOptions;
|
|
11
|
+
|
|
12
|
+
const rules: QualifiedRules = {
|
|
13
|
+
'body-leading-blank': [Warning, 'always'],
|
|
14
|
+
'body-max-line-length': [Error, 'always', 100],
|
|
15
|
+
'footer-leading-blank': [Warning, 'always'],
|
|
16
|
+
'footer-max-line-length': [Error, 'always', 100],
|
|
17
|
+
'header-max-length': [Error, 'always', 100],
|
|
18
|
+
'scope-case': [Error, 'always', 'lower-case'],
|
|
19
|
+
'subject-case': [Error, 'always', ['sentence-case']],
|
|
20
|
+
'subject-empty': [Error, 'never'],
|
|
21
|
+
'subject-exclamation-mark': [Error, 'never'],
|
|
22
|
+
'subject-full-stop': [Error, 'never', '.'],
|
|
23
|
+
'type-case': [Error, 'always', 'lower-case'],
|
|
24
|
+
'type-empty': [Error, 'never'],
|
|
25
|
+
'type-enum': [Disabled],
|
|
26
|
+
'type-gitmoji-style': [Error, 'always', 'unicode'],
|
|
27
|
+
'type-valid-gitmoji': [Error, 'always'],
|
|
28
|
+
};
|
|
29
|
+
|
|
30
|
+
export const config = {
|
|
31
|
+
parserPreset,
|
|
32
|
+
rules,
|
|
33
|
+
plugins: [gitmojiPlugin],
|
|
34
|
+
};
|
package/src/index.ts
CHANGED
|
@@ -1,36 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
import { gitmojiPlugin } from './plugin.js';
|
|
4
|
-
|
|
5
|
-
const { Error, Warning, Disabled } = RuleConfigSeverity;
|
|
6
|
-
|
|
7
|
-
const parserPreset = {
|
|
8
|
-
// eslint-disable-next-line unicorn/no-await-expression-member
|
|
9
|
-
parserOpts: (await conventionalChangelogPreset()).parser as any,
|
|
10
|
-
} satisfies LintOptions;
|
|
11
|
-
|
|
12
|
-
const rules: QualifiedRules = {
|
|
13
|
-
'body-leading-blank': [Warning, 'always'],
|
|
14
|
-
'body-max-line-length': [Error, 'always', 100],
|
|
15
|
-
'footer-leading-blank': [Warning, 'always'],
|
|
16
|
-
'footer-max-line-length': [Error, 'always', 100],
|
|
17
|
-
'header-max-length': [Error, 'always', 100],
|
|
18
|
-
'scope-case': [Error, 'always', 'lower-case'],
|
|
19
|
-
'subject-case': [Error, 'always', ['sentence-case']],
|
|
20
|
-
'subject-empty': [Error, 'never'],
|
|
21
|
-
'subject-exclamation-mark': [Error, 'never'],
|
|
22
|
-
'subject-full-stop': [Error, 'never', '.'],
|
|
23
|
-
'type-case': [Error, 'always', 'lower-case'],
|
|
24
|
-
'type-empty': [Error, 'never'],
|
|
25
|
-
'type-enum': [Disabled],
|
|
26
|
-
'type-gitmoji-style': [Error, 'always', 'unicode'],
|
|
27
|
-
'type-valid-gitmoji': [Error, 'always'],
|
|
28
|
-
};
|
|
29
|
-
|
|
30
|
-
const config = {
|
|
31
|
-
parserPreset,
|
|
32
|
-
rules,
|
|
33
|
-
plugins: [gitmojiPlugin],
|
|
34
|
-
};
|
|
35
|
-
|
|
36
|
-
export default config;
|
|
1
|
+
export * from './meta.js';
|
|
2
|
+
export { config as default } from './config.js';
|
package/src/meta.ts
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export const meta = Object.freeze({
|
|
2
|
+
// @ts-ignore - these variables are injected at build time
|
|
3
|
+
name: (typeof __PACKAGE_NAME__ === 'undefined' ? '' : __PACKAGE_NAME__) as string,
|
|
4
|
+
// @ts-ignore - these variables are injected at build time
|
|
5
|
+
version: (typeof __PACKAGE_VERSION__ === 'undefined' ? '' : __PACKAGE_VERSION__) as string,
|
|
6
|
+
// @ts-ignore - these variables are injected at build time
|
|
7
|
+
buildNumber: 1 as number, // (typeof __PACKAGE_BUILD_NUMBER__ === 'undefined' ? 0 : __PACKAGE_BUILD_NUMBER__) as number,
|
|
8
|
+
});
|