@grafana/plugin-types-bundler 0.0.2 → 0.0.3-canary.1164.7436ea1.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/dist/utils.js +4 -2
- package/package.json +5 -4
- package/src/bundleTypes.ts +1 -0
- package/src/utils.ts +4 -2
- package/tsconfig/tsconfig.json +7 -0
package/dist/utils.js
CHANGED
@@ -1,6 +1,8 @@
|
|
1
1
|
import parseArgs from 'minimist';
|
2
|
-
import { join } from 'node:path';
|
2
|
+
import { join, resolve } from 'node:path';
|
3
|
+
import { fileURLToPath } from 'node:url';
|
3
4
|
const args = process.argv.slice(2);
|
5
|
+
const __dirname = fileURLToPath(new URL('.', import.meta.url));
|
4
6
|
export const parsedArgs = parseArgs(args, {
|
5
7
|
alias: {
|
6
8
|
entryPoint: 'entry-point',
|
@@ -14,7 +16,7 @@ export const parsedArgs = parseArgs(args, {
|
|
14
16
|
},
|
15
17
|
default: {
|
16
18
|
entryPoint: undefined,
|
17
|
-
tsConfig:
|
19
|
+
tsConfig: resolve(__dirname, '../tsconfig', 'tsconfig.json'),
|
18
20
|
outDir: join(process.cwd(), 'dist'),
|
19
21
|
},
|
20
22
|
});
|
package/package.json
CHANGED
@@ -1,14 +1,15 @@
|
|
1
1
|
{
|
2
2
|
"name": "@grafana/plugin-types-bundler",
|
3
|
-
"version": "0.0.
|
3
|
+
"version": "0.0.3-canary.1164.7436ea1.0",
|
4
4
|
"description": "Bundle grafana plugin typescript types for sharing with other plugins",
|
5
5
|
"bin": "./dist/bin/run.js",
|
6
6
|
"type": "module",
|
7
7
|
"exports": {
|
8
|
-
"
|
8
|
+
".": {
|
9
9
|
"import": "./dist/bundleTypes.js"
|
10
10
|
},
|
11
|
-
"
|
11
|
+
"./package.json": "./package.json",
|
12
|
+
"./tsconfig.json": "./tsconfig/tsconfig.json"
|
12
13
|
},
|
13
14
|
"scripts": {
|
14
15
|
"test": "vitest --passWithNoTests",
|
@@ -49,5 +50,5 @@
|
|
49
50
|
"jackw-dts-bundle-gen-test": "^9.5.1",
|
50
51
|
"minimist": "^1.2.8"
|
51
52
|
},
|
52
|
-
"gitHead": "
|
53
|
+
"gitHead": "7436ea180c7800bf573e94e06354347ce09372fc"
|
53
54
|
}
|
package/src/bundleTypes.ts
CHANGED
package/src/utils.ts
CHANGED
@@ -1,7 +1,9 @@
|
|
1
1
|
import parseArgs from 'minimist';
|
2
|
-
import { join } from 'node:path';
|
2
|
+
import { join, resolve } from 'node:path';
|
3
|
+
import { fileURLToPath } from 'node:url';
|
3
4
|
|
4
5
|
const args = process.argv.slice(2);
|
6
|
+
const __dirname = fileURLToPath(new URL('.', import.meta.url));
|
5
7
|
|
6
8
|
export type ParsedArgs = {
|
7
9
|
entryPoint?: string;
|
@@ -22,7 +24,7 @@ export const parsedArgs = parseArgs<ParsedArgs>(args, {
|
|
22
24
|
},
|
23
25
|
default: {
|
24
26
|
entryPoint: undefined,
|
25
|
-
tsConfig:
|
27
|
+
tsConfig: resolve(__dirname, '../tsconfig', 'tsconfig.json'),
|
26
28
|
outDir: join(process.cwd(), 'dist'),
|
27
29
|
},
|
28
30
|
});
|