@grafana/create-plugin 2.0.2 → 2.0.3-canary.451.a455f3e.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/package.json +2 -2
- package/templates/common/.config/.eslintrc +1 -1
- package/templates/common/.config/.prettierrc.js +9 -9
- package/templates/common/.config/tsconfig.json +1 -1
- package/templates/common/.config/webpack/utils.ts +3 -4
- package/templates/common/.config/webpack/webpack.config.ts +1 -1
- package/templates/common/.eslintrc +1 -1
- package/templates/common/.nvmrc +1 -1
- package/templates/common/.prettierrc.js +2 -2
- package/templates/common/CHANGELOG.md +1 -1
- package/templates/common/tsconfig.json +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@grafana/create-plugin",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.3-canary.451.a455f3e.0",
|
|
4
4
|
"main": "index.js",
|
|
5
5
|
"repository": {
|
|
6
6
|
"directory": "packages/create-plugin",
|
|
@@ -66,5 +66,5 @@
|
|
|
66
66
|
"engines": {
|
|
67
67
|
"node": ">=18"
|
|
68
68
|
},
|
|
69
|
-
"gitHead": "
|
|
69
|
+
"gitHead": "a455f3e34e0d7c2e9775ecce1d1a68b4a6fc6d8e"
|
|
70
70
|
}
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* In order to extend the configuration follow the steps in
|
|
5
5
|
* https://grafana.com/developers/plugin-tools/create-a-plugin/extend-a-plugin/extend-configurations#extend-the-eslint-config
|
|
6
6
|
*/
|
|
7
|
-
|
|
7
|
+
{
|
|
8
8
|
"extends": ["@grafana/eslint-config"],
|
|
9
9
|
"root": true,
|
|
10
10
|
"rules": {
|
|
@@ -5,12 +5,12 @@
|
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
7
|
module.exports = {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
};
|
|
8
|
+
endOfLine: 'auto',
|
|
9
|
+
printWidth: 120,
|
|
10
|
+
trailingComma: 'es5',
|
|
11
|
+
semi: true,
|
|
12
|
+
jsxSingleQuote: false,
|
|
13
|
+
singleQuote: true,
|
|
14
|
+
useTabs: false,
|
|
15
|
+
tabWidth: 2,
|
|
16
|
+
};
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* In order to extend the configuration follow the steps in
|
|
5
5
|
* https://grafana.com/developers/plugin-tools/create-a-plugin/extend-a-plugin/extend-configurations#extend-the-typescript-config
|
|
6
6
|
*/
|
|
7
|
-
|
|
7
|
+
{
|
|
8
8
|
"compilerOptions": {
|
|
9
9
|
"alwaysStrict": true,
|
|
10
10
|
"declaration": false,
|
|
@@ -2,11 +2,9 @@ import fs from 'fs';
|
|
|
2
2
|
import process from 'process';
|
|
3
3
|
import os from 'os';
|
|
4
4
|
import path from 'path';
|
|
5
|
-
import util from 'util';
|
|
6
5
|
import { glob } from 'glob';
|
|
7
6
|
import { SOURCE_DIR } from './constants';
|
|
8
7
|
|
|
9
|
-
|
|
10
8
|
export function isWSL() {
|
|
11
9
|
if (process.platform !== 'linux') {
|
|
12
10
|
return false;
|
|
@@ -21,7 +19,7 @@ export function isWSL() {
|
|
|
21
19
|
} catch {
|
|
22
20
|
return false;
|
|
23
21
|
}
|
|
24
|
-
}
|
|
22
|
+
}
|
|
25
23
|
|
|
26
24
|
export function getPackageJson() {
|
|
27
25
|
return require(path.resolve(process.cwd(), 'package.json'));
|
|
@@ -40,7 +38,8 @@ export function hasReadme() {
|
|
|
40
38
|
export async function getEntries(): Promise<Record<string, string>> {
|
|
41
39
|
const pluginsJson = await glob('**/src/**/plugin.json', { absolute: true });
|
|
42
40
|
|
|
43
|
-
const plugins = await Promise.all(
|
|
41
|
+
const plugins = await Promise.all(
|
|
42
|
+
pluginsJson.map((pluginJson) => {
|
|
44
43
|
const folder = path.dirname(pluginJson);
|
|
45
44
|
return glob(`${folder}/module.{ts,tsx,js,jsx}`, { absolute: true });
|
|
46
45
|
})
|
package/templates/common/.nvmrc
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
18
|