@equinor/roma-nx-plugin 6.2.0 → 6.4.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/CHANGELOG.md +116 -247
- package/README.md +5 -0
- package/biome-baseline.json +95 -0
- package/executors.json +5 -0
- package/generators.json +5 -0
- package/migrations.json +151 -0
- package/package.json +18 -17
- package/src/executors/build/build.d.ts +1 -1
- package/src/executors/build/build.js +3 -3
- package/src/executors/build/build.js.map +1 -1
- package/src/executors/build/executor.d.ts +1 -1
- package/src/executors/build/executor.js.map +1 -1
- package/src/executors/build/minify.d.ts +1 -1
- package/src/executors/build/minify.js.map +1 -1
- package/src/executors/build/normalizeRootForFusion.d.ts +1 -1
- package/src/executors/build/normalizeRootForFusion.js.map +1 -1
- package/src/executors/build/schema.d.ts +1 -1
- package/src/executors/build/schema.json +1 -2
- package/src/executors/component-test/executor.d.ts +2 -2
- package/src/executors/component-test/executor.js +1 -1
- package/src/executors/component-test/executor.js.map +1 -1
- package/src/executors/create-vite-config.d.ts +1 -1
- package/src/executors/create-vite-config.js +8 -11
- package/src/executors/create-vite-config.js.map +1 -1
- package/src/executors/executor-context.d.ts +1 -1
- package/src/executors/lint/biome.d.ts +3 -0
- package/src/executors/lint/biome.js +18 -0
- package/src/executors/lint/biome.js.map +1 -0
- package/src/executors/lint/boundaries.d.ts +14 -0
- package/src/executors/lint/boundaries.js +41 -0
- package/src/executors/lint/boundaries.js.map +1 -0
- package/src/executors/lint/executor.d.ts +5 -0
- package/src/executors/lint/executor.js +65 -0
- package/src/executors/lint/executor.js.map +1 -0
- package/src/executors/lint/schema.d.ts +7 -0
- package/src/executors/lint/schema.json +37 -0
- package/src/executors/publish/environment.d.ts +0 -1
- package/src/executors/publish/executor.d.ts +2 -2
- package/src/executors/publish/manifest-model.d.ts +3 -1
- package/src/executors/publish/publish-script.js +3 -3
- package/src/executors/publish/publish-script.js.map +1 -1
- package/src/executors/publish/readme.md +5 -5
- package/src/executors/publish/schema.d.ts +1 -1
- package/src/executors/serve/executor.d.ts +2 -2
- package/src/executors/serve/get-manifest.d.ts +1 -1
- package/src/executors/serve/get-manifest.js +1 -1
- package/src/executors/serve/get-manifest.js.map +1 -1
- package/src/executors/serve/readme.md +1 -1
- package/src/executors/serve/schema.json +1 -1
- package/src/executors/serve/server.d.ts +1 -1
- package/src/executors/serve/server.js +22 -15
- package/src/executors/serve/server.js.map +1 -1
- package/src/executors/utils/csp/csp-check-plugin.js.map +1 -1
- package/src/executors/utils/csp/data/generated-csp.json +1 -1
- package/src/executors/utils/csp/extract-urls.js +4 -6
- package/src/executors/utils/csp/extract-urls.js.map +1 -1
- package/src/executors/utils/load-services.js.map +1 -1
- package/src/executors/utils/logger.d.ts +2 -2
- package/src/executors/utils/logger.js +6 -2
- package/src/executors/utils/logger.js.map +1 -1
- package/src/executors/utils/read-manifest.d.ts +1 -1
- package/src/executors/utils/read-manifest.js.map +1 -1
- package/src/executors/utils/verify-manifest.d.ts +1 -1
- package/src/generators/app/data/generated-dependencies.json +17 -17
- package/src/generators/app/files/src/App.tsx.template +1 -1
- package/src/generators/app/files/src/config.ts.template +1 -2
- package/src/generators/app/files/src/index.ts.template +3 -5
- package/src/generators/app/files/vite.config.mts.template +1 -1
- package/src/generators/app/files/vite.config.ts.template +1 -1
- package/src/generators/app/files-routing/src/routes.ts.template +1 -1
- package/src/generators/app/generator.d.ts +3 -3
- package/src/generators/app/generator.js +5 -3
- package/src/generators/app/generator.js.map +1 -1
- package/src/generators/app/readme.md +1 -1
- package/src/generators/app/schema.json +5 -35
- package/src/generators/component-test/generator.d.ts +2 -2
- package/src/generators/lint-setup/generator.d.ts +6 -0
- package/src/generators/lint-setup/generator.js +115 -0
- package/src/generators/lint-setup/generator.js.map +1 -0
- package/src/generators/lint-setup/schema.d.ts +5 -0
- package/src/generators/lint-setup/schema.json +27 -0
- package/src/generators/preset/generator.d.ts +2 -2
- package/src/generators/preset/schema.json +4 -32
- package/src/generators/skill/files/creating-dashboard-descriptors/SKILL.md +149 -0
- package/src/generators/skill/files/roma-app-development/SKILL.md +34 -1
- package/src/generators/skill/files/roma-app-development/generators.md +19 -9
- package/src/generators/skill/files/roma-dashboard-mcp/SKILL.md +74 -0
- package/src/generators/skill/files/roma-dashboard-mcp/scripts/roma-mcp-bridge.mjs +227 -0
- package/src/generators/skill/generator.d.ts +2 -2
- package/src/generators/skill/generator.js.map +1 -1
- package/src/migrations/add-publish-target/add-publish-target.d.ts +1 -1
- package/src/migrations/add-publish-target/add-publish-target.js.map +1 -1
- package/src/migrations/migrate-fusion-manifest/migrate-fusion-manifest.d.ts +1 -1
- package/src/migrations/migrate-fusion-manifest/migrate-fusion-manifest.js.map +1 -1
- package/src/migrations/migrate-fusion-manifest/old-format.json +1 -3
- package/src/migrations/migrate-fusion-manifest/update-manifest.d.ts +3 -3
- package/src/migrations/migrate-fusion-manifest/update-manifest.js.map +1 -1
- package/src/migrations/migrate-fusion-router/detect.d.ts +1 -1
- package/src/migrations/migrate-fusion-router/detect.js.map +1 -1
- package/src/migrations/migrate-fusion-router/ensure-default-exports.d.ts +1 -1
- package/src/migrations/migrate-fusion-router/ensure-default-exports.js.map +1 -1
- package/src/migrations/migrate-fusion-router/generate-routes-file.d.ts +1 -1
- package/src/migrations/migrate-fusion-router/generate-routes-file.js +12 -4
- package/src/migrations/migrate-fusion-router/generate-routes-file.js.map +1 -1
- package/src/migrations/migrate-fusion-router/migrate-fusion-router.d.ts +1 -1
- package/src/migrations/migrate-fusion-router/migrate-fusion-router.js +9 -4
- package/src/migrations/migrate-fusion-router/migrate-fusion-router.js.map +1 -1
- package/src/migrations/migrate-fusion-router/transform-app.js +27 -13
- package/src/migrations/migrate-fusion-router/transform-app.js.map +1 -1
- package/src/migrations/migrate-fusion-router/update-vite-config.js.map +1 -1
- package/src/migrations/migrate-global-navigation/migrate-global-navigation.d.ts +1 -1
- package/src/migrations/migrate-global-navigation/migrate-global-navigation.js.map +1 -1
- package/src/migrations/migrate-to-biome/migrate-to-biome.d.ts +2 -0
- package/src/migrations/migrate-to-biome/migrate-to-biome.js +19 -0
- package/src/migrations/migrate-to-biome/migrate-to-biome.js.map +1 -0
- package/src/migrations/move-fusion-manifest/move-fusion-manifest.d.ts +1 -1
- package/src/migrations/move-fusion-manifest/move-fusion-manifest.js +0 -1
- package/src/migrations/move-fusion-manifest/move-fusion-manifest.js.map +1 -1
- package/src/migrations/remove-fusion-cli/remove-fusion-cli.d.ts +1 -1
- package/src/migrations/remove-fusion-cli/remove-fusion-cli.js +0 -1
- package/src/migrations/remove-fusion-cli/remove-fusion-cli.js.map +1 -1
- package/src/migrations/swap-eds-to-roma-ui/swap-eds-to-roma-ui.d.ts +10 -0
- package/src/migrations/swap-eds-to-roma-ui/swap-eds-to-roma-ui.js +86 -0
- package/src/migrations/swap-eds-to-roma-ui/swap-eds-to-roma-ui.js.map +1 -0
- package/src/migrations/update-acquire-access-token/README.md +2 -1
- package/src/migrations/update-acquire-access-token/update-acquire-access-token.d.ts +1 -1
- package/src/generators/app/files/eslint.config.js.template +0 -105
package/README.md
CHANGED
|
@@ -40,3 +40,8 @@ nx run roma:generate-csp
|
|
|
40
40
|
The check is disabled automatically (no warnings) if the bundled snapshot is missing or
|
|
41
41
|
unparseable.
|
|
42
42
|
|
|
43
|
+
## Linting
|
|
44
|
+
|
|
45
|
+
The `lint` executor runs the pinned Biome version with `biome-baseline.json` and checks tag-based module
|
|
46
|
+
boundaries. `nx g @equinor/roma-nx-plugin:lint-setup --all` migrates projects from ESLint, and the
|
|
47
|
+
`migrate-to-biome` migration (v7) does the same automatically. Docs: roma-docs → Nx Plugin → Linting.
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://biomejs.dev/schemas/2.6.9/schema.json",
|
|
3
|
+
"root": true,
|
|
4
|
+
"files": {
|
|
5
|
+
"ignoreUnknown": true,
|
|
6
|
+
"includes": [
|
|
7
|
+
"**",
|
|
8
|
+
"!**/dist",
|
|
9
|
+
"!**/node_modules",
|
|
10
|
+
"!**/coverage",
|
|
11
|
+
"!**/*.timestamp*",
|
|
12
|
+
"!**/*.md",
|
|
13
|
+
"!**/*.mdx",
|
|
14
|
+
"!**/*.yml",
|
|
15
|
+
"!**/*.yaml",
|
|
16
|
+
"!**/.nx",
|
|
17
|
+
"!**/out-tsc",
|
|
18
|
+
"!**/tmp"
|
|
19
|
+
]
|
|
20
|
+
},
|
|
21
|
+
"formatter": {
|
|
22
|
+
"enabled": true,
|
|
23
|
+
"indentStyle": "space",
|
|
24
|
+
"indentWidth": 2,
|
|
25
|
+
"lineWidth": 80,
|
|
26
|
+
"lineEnding": "lf"
|
|
27
|
+
},
|
|
28
|
+
"javascript": {
|
|
29
|
+
"formatter": {
|
|
30
|
+
"quoteStyle": "single",
|
|
31
|
+
"jsxQuoteStyle": "double",
|
|
32
|
+
"trailingCommas": "es5",
|
|
33
|
+
"semicolons": "always"
|
|
34
|
+
}
|
|
35
|
+
},
|
|
36
|
+
"assist": {
|
|
37
|
+
"enabled": true,
|
|
38
|
+
"actions": {
|
|
39
|
+
"source": {
|
|
40
|
+
"organizeImports": "on"
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
"linter": {
|
|
45
|
+
"enabled": true,
|
|
46
|
+
"rules": {
|
|
47
|
+
"preset": "recommended",
|
|
48
|
+
"suspicious": {
|
|
49
|
+
"noExplicitAny": "warn",
|
|
50
|
+
"noArrayIndexKey": "error"
|
|
51
|
+
},
|
|
52
|
+
"style": {
|
|
53
|
+
"useConsistentTypeDefinitions": {
|
|
54
|
+
"level": "warn",
|
|
55
|
+
"options": {
|
|
56
|
+
"style": "type"
|
|
57
|
+
}
|
|
58
|
+
},
|
|
59
|
+
"useConsistentArrayType": {
|
|
60
|
+
"level": "warn",
|
|
61
|
+
"options": {
|
|
62
|
+
"syntax": "generic"
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
},
|
|
66
|
+
"correctness": {
|
|
67
|
+
"useExhaustiveDependencies": "error",
|
|
68
|
+
"useHookAtTopLevel": "error"
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
},
|
|
72
|
+
"overrides": [
|
|
73
|
+
{
|
|
74
|
+
"includes": [
|
|
75
|
+
"**/*.spec.ts",
|
|
76
|
+
"**/*.spec.tsx",
|
|
77
|
+
"**/*.test.ts",
|
|
78
|
+
"**/*.test.tsx",
|
|
79
|
+
"**/*.cy.ts",
|
|
80
|
+
"**/*.cy.tsx"
|
|
81
|
+
],
|
|
82
|
+
"linter": {
|
|
83
|
+
"rules": {
|
|
84
|
+
"a11y": "off",
|
|
85
|
+
"suspicious": {
|
|
86
|
+
"noExplicitAny": "off"
|
|
87
|
+
},
|
|
88
|
+
"correctness": {
|
|
89
|
+
"noComponentHookFactories": "off"
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
]
|
|
95
|
+
}
|
package/executors.json
CHANGED
|
@@ -19,6 +19,11 @@
|
|
|
19
19
|
"implementation": "./src/executors/component-test/executor",
|
|
20
20
|
"schema": "./src/executors/component-test/schema.json",
|
|
21
21
|
"description": "Run cypress component tests"
|
|
22
|
+
},
|
|
23
|
+
"lint": {
|
|
24
|
+
"implementation": "./src/executors/lint/executor",
|
|
25
|
+
"schema": "./src/executors/lint/schema.json",
|
|
26
|
+
"description": "Lint and format-check a project with the Roma Biome baseline and check module boundaries"
|
|
22
27
|
}
|
|
23
28
|
}
|
|
24
29
|
}
|
package/generators.json
CHANGED
|
@@ -20,6 +20,11 @@
|
|
|
20
20
|
"factory": "./src/generators/skill/generator",
|
|
21
21
|
"schema": "./src/generators/skill/schema.json",
|
|
22
22
|
"description": "Add the Roma development skill for AI assistants"
|
|
23
|
+
},
|
|
24
|
+
"lint-setup": {
|
|
25
|
+
"factory": "./src/generators/lint-setup/generator",
|
|
26
|
+
"schema": "./src/generators/lint-setup/schema.json",
|
|
27
|
+
"description": "Switch projects from ESLint to the Roma Biome lint executor"
|
|
23
28
|
}
|
|
24
29
|
}
|
|
25
30
|
}
|
package/migrations.json
CHANGED
|
@@ -34,6 +34,16 @@
|
|
|
34
34
|
"version": "6.2.0-beta.0",
|
|
35
35
|
"description": "Migrate apps to fusion-framework-react-router v2 Router component",
|
|
36
36
|
"implementation": "./src/migrations/migrate-fusion-router/migrate-fusion-router"
|
|
37
|
+
},
|
|
38
|
+
"swap-eds-to-roma-ui": {
|
|
39
|
+
"version": "6.3.0-beta.0",
|
|
40
|
+
"description": "Swap @equinor/eds-core-react imports and dependency for @equinor/roma-ui",
|
|
41
|
+
"implementation": "./src/migrations/swap-eds-to-roma-ui/swap-eds-to-roma-ui"
|
|
42
|
+
},
|
|
43
|
+
"migrate-to-biome": {
|
|
44
|
+
"version": "7.0.0",
|
|
45
|
+
"description": "Replace ESLint with the Roma Biome lint executor (@equinor/roma-nx-plugin:lint)",
|
|
46
|
+
"implementation": "./src/migrations/migrate-to-biome/migrate-to-biome"
|
|
37
47
|
}
|
|
38
48
|
},
|
|
39
49
|
"packageJsonUpdates": {
|
|
@@ -599,6 +609,147 @@
|
|
|
599
609
|
"@equinor/fusion-framework-react-module": { "version": "4.0.0" },
|
|
600
610
|
"@equinor/fusion-framework-react-module-http": { "version": "11.0.0" }
|
|
601
611
|
}
|
|
612
|
+
},
|
|
613
|
+
"upgrade-fusion-6-3": {
|
|
614
|
+
"version": "6.3.0",
|
|
615
|
+
"packages": {
|
|
616
|
+
"@equinor/eds-core-react": {
|
|
617
|
+
"version": "^2.6.4",
|
|
618
|
+
"alwaysAddToPackageJson": false
|
|
619
|
+
},
|
|
620
|
+
"@equinor/eds-icons": {
|
|
621
|
+
"version": "^1.6.0",
|
|
622
|
+
"alwaysAddToPackageJson": false
|
|
623
|
+
},
|
|
624
|
+
"@equinor/eds-tokens": {
|
|
625
|
+
"version": "^2.3.2",
|
|
626
|
+
"alwaysAddToPackageJson": false
|
|
627
|
+
},
|
|
628
|
+
"@equinor/fusion-framework": {
|
|
629
|
+
"version": "^9.1.0",
|
|
630
|
+
"alwaysAddToPackageJson": false
|
|
631
|
+
},
|
|
632
|
+
"@equinor/fusion-framework-app": {
|
|
633
|
+
"version": "^13.3.0",
|
|
634
|
+
"alwaysAddToPackageJson": false
|
|
635
|
+
},
|
|
636
|
+
"@equinor/fusion-framework-module": {
|
|
637
|
+
"version": "^6.2.0",
|
|
638
|
+
"alwaysAddToPackageJson": false
|
|
639
|
+
},
|
|
640
|
+
"@equinor/fusion-framework-module-app": {
|
|
641
|
+
"version": "^8.3.0",
|
|
642
|
+
"alwaysAddToPackageJson": false
|
|
643
|
+
},
|
|
644
|
+
"@equinor/fusion-framework-module-context": {
|
|
645
|
+
"version": "^9.1.0",
|
|
646
|
+
"alwaysAddToPackageJson": false
|
|
647
|
+
},
|
|
648
|
+
"@equinor/fusion-framework-module-event": {
|
|
649
|
+
"version": "^6.1.4",
|
|
650
|
+
"alwaysAddToPackageJson": false
|
|
651
|
+
},
|
|
652
|
+
"@equinor/fusion-framework-module-feature-flag": {
|
|
653
|
+
"version": "^2.2.0",
|
|
654
|
+
"alwaysAddToPackageJson": false
|
|
655
|
+
},
|
|
656
|
+
"@equinor/fusion-framework-module-http": {
|
|
657
|
+
"version": "^8.1.5",
|
|
658
|
+
"alwaysAddToPackageJson": false
|
|
659
|
+
},
|
|
660
|
+
"@equinor/fusion-framework-module-msal": {
|
|
661
|
+
"version": "^12.1.0",
|
|
662
|
+
"alwaysAddToPackageJson": false
|
|
663
|
+
},
|
|
664
|
+
"@equinor/fusion-framework-module-navigation": {
|
|
665
|
+
"version": "^8.0.0",
|
|
666
|
+
"alwaysAddToPackageJson": false
|
|
667
|
+
},
|
|
668
|
+
"@equinor/fusion-framework-module-service-discovery": {
|
|
669
|
+
"version": "^10.3.0",
|
|
670
|
+
"alwaysAddToPackageJson": false
|
|
671
|
+
},
|
|
672
|
+
"@equinor/fusion-framework-react": {
|
|
673
|
+
"version": "^9.0.5",
|
|
674
|
+
"alwaysAddToPackageJson": false
|
|
675
|
+
},
|
|
676
|
+
"@equinor/fusion-framework-react-app": {
|
|
677
|
+
"version": "^14.3.9",
|
|
678
|
+
"alwaysAddToPackageJson": false
|
|
679
|
+
},
|
|
680
|
+
"@equinor/fusion-framework-react-module": {
|
|
681
|
+
"version": "^4.0.7",
|
|
682
|
+
"alwaysAddToPackageJson": false
|
|
683
|
+
},
|
|
684
|
+
"@equinor/fusion-framework-react-module-context": {
|
|
685
|
+
"version": "^7.0.8",
|
|
686
|
+
"alwaysAddToPackageJson": false
|
|
687
|
+
},
|
|
688
|
+
"@equinor/fusion-framework-react-module-http": {
|
|
689
|
+
"version": "^12.0.4",
|
|
690
|
+
"alwaysAddToPackageJson": false
|
|
691
|
+
},
|
|
692
|
+
"@equinor/fusion-framework-react-router": {
|
|
693
|
+
"version": "^2.4.8",
|
|
694
|
+
"alwaysAddToPackageJson": false
|
|
695
|
+
},
|
|
696
|
+
"@equinor/roma-dynatrace-module": {
|
|
697
|
+
"version": "^0.2.0",
|
|
698
|
+
"alwaysAddToPackageJson": false
|
|
699
|
+
},
|
|
700
|
+
"@equinor/roma-framework": {
|
|
701
|
+
"version": "^6.2.0",
|
|
702
|
+
"alwaysAddToPackageJson": false
|
|
703
|
+
},
|
|
704
|
+
"@equinor/roma-page-title-module": {
|
|
705
|
+
"version": "^1.2.0",
|
|
706
|
+
"alwaysAddToPackageJson": false
|
|
707
|
+
},
|
|
708
|
+
"@equinor/roma-page-title-module-react": {
|
|
709
|
+
"version": "^1.2.0",
|
|
710
|
+
"alwaysAddToPackageJson": false
|
|
711
|
+
},
|
|
712
|
+
"@equinor/roma-query-module": {
|
|
713
|
+
"version": "^0.2.0",
|
|
714
|
+
"alwaysAddToPackageJson": false
|
|
715
|
+
},
|
|
716
|
+
"@equinor/roma-settings-module": {
|
|
717
|
+
"version": "^0.2.0",
|
|
718
|
+
"alwaysAddToPackageJson": false
|
|
719
|
+
},
|
|
720
|
+
"@equinor/roma-sse-module": {
|
|
721
|
+
"version": "^1.2.0",
|
|
722
|
+
"alwaysAddToPackageJson": false
|
|
723
|
+
},
|
|
724
|
+
"@equinor/roma-sse-module-react": {
|
|
725
|
+
"version": "^1.2.0",
|
|
726
|
+
"alwaysAddToPackageJson": false
|
|
727
|
+
},
|
|
728
|
+
"@equinor/roma-ui": {
|
|
729
|
+
"version": "^1.4.0",
|
|
730
|
+
"alwaysAddToPackageJson": false
|
|
731
|
+
},
|
|
732
|
+
"@tanstack/react-query": {
|
|
733
|
+
"version": "5.107.1",
|
|
734
|
+
"alwaysAddToPackageJson": false
|
|
735
|
+
},
|
|
736
|
+
"@tanstack/react-query-devtools": {
|
|
737
|
+
"version": "5.107.1",
|
|
738
|
+
"alwaysAddToPackageJson": false
|
|
739
|
+
},
|
|
740
|
+
"@tanstack/react-query-persist-client": {
|
|
741
|
+
"version": "5.107.1",
|
|
742
|
+
"alwaysAddToPackageJson": false
|
|
743
|
+
},
|
|
744
|
+
"react": {
|
|
745
|
+
"version": "^19.3.1",
|
|
746
|
+
"alwaysAddToPackageJson": false
|
|
747
|
+
},
|
|
748
|
+
"react-dom": {
|
|
749
|
+
"version": "^19.3.1",
|
|
750
|
+
"alwaysAddToPackageJson": false
|
|
751
|
+
}
|
|
752
|
+
}
|
|
602
753
|
}
|
|
603
754
|
}
|
|
604
755
|
}
|
package/package.json
CHANGED
|
@@ -1,28 +1,29 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@equinor/roma-nx-plugin",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "6.
|
|
4
|
+
"version": "6.4.0",
|
|
5
5
|
"repository": "https://github.com/equinor/tops-roma",
|
|
6
6
|
"dependencies": {
|
|
7
|
-
"@azure/identity": "^4.
|
|
8
|
-
"@
|
|
9
|
-
"@equinor/
|
|
10
|
-
"@
|
|
11
|
-
"@nx/
|
|
12
|
-
"@
|
|
13
|
-
"
|
|
14
|
-
"
|
|
15
|
-
"
|
|
7
|
+
"@azure/identity": "^4.14.1",
|
|
8
|
+
"@biomejs/biome": "2.6.9",
|
|
9
|
+
"@equinor/fusion-framework-module-app": "8.3.0",
|
|
10
|
+
"@equinor/roma-framework": "6.2.0",
|
|
11
|
+
"@nx/devkit": "^22.7.12",
|
|
12
|
+
"@nx/react": "^22.7.12",
|
|
13
|
+
"@vitejs/plugin-react": "^6.3.0",
|
|
14
|
+
"cypress": "^15.21.2",
|
|
15
|
+
"esbuild": "0.27.7",
|
|
16
|
+
"express": "^4.22.3",
|
|
16
17
|
"get-port": "^7.2.0",
|
|
17
|
-
"http-proxy-middleware": "^3.0.
|
|
18
|
+
"http-proxy-middleware": "^3.0.10",
|
|
18
19
|
"open": "^10.2.0",
|
|
19
|
-
"rollup": "^4.
|
|
20
|
-
"semver": "6.3.
|
|
20
|
+
"rollup": "^4.68.3",
|
|
21
|
+
"semver": "6.3.2",
|
|
21
22
|
"ts-morph": "^25.0.1",
|
|
22
|
-
"tslib": "^2.
|
|
23
|
-
"vite": "^8.
|
|
24
|
-
"vite-plugin-checker": "^0.14.
|
|
25
|
-
"vite-plugin-environment": "^1.1.
|
|
23
|
+
"tslib": "^2.9.1",
|
|
24
|
+
"vite": "^8.3.8",
|
|
25
|
+
"vite-plugin-checker": "^0.14.5",
|
|
26
|
+
"vite-plugin-environment": "^1.1.4"
|
|
26
27
|
},
|
|
27
28
|
"peerDependencies": {
|
|
28
29
|
"@nx/devkit": "^22.0.3",
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.default = default_1;
|
|
4
|
-
const create_vite_config_1 = require("../create-vite-config");
|
|
5
|
-
const vite_1 = require("vite");
|
|
6
4
|
const node_fs_1 = require("node:fs");
|
|
7
5
|
const node_path_1 = require("node:path");
|
|
8
6
|
const path_1 = require("path");
|
|
9
|
-
const
|
|
7
|
+
const vite_1 = require("vite");
|
|
8
|
+
const create_vite_config_1 = require("../create-vite-config");
|
|
10
9
|
const get_vite_config_1 = require("../utils/get-vite-config");
|
|
10
|
+
const logger_1 = require("../utils/logger");
|
|
11
11
|
const read_manifest_1 = require("../utils/read-manifest");
|
|
12
12
|
const logger = new logger_1.Logger();
|
|
13
13
|
async function default_1(context, watch = false) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"build.js","sourceRoot":"","sources":["../../../../../../plugins/roma/src/executors/build/build.ts"],"names":[],"mappings":";;AAaA,4BA0CC;AAvDD,
|
|
1
|
+
{"version":3,"file":"build.js","sourceRoot":"","sources":["../../../../../../plugins/roma/src/executors/build/build.ts"],"names":[],"mappings":";;AAaA,4BA0CC;AAvDD,qCAAwC;AACxC,yCAAiC;AAEjC,+BAA+B;AAE/B,+BAAiD;AACjD,8DAA6D;AAC7D,8DAAyD;AACzD,4CAAyC;AACzC,0DAAsD;AAEtD,MAAM,MAAM,GAAG,IAAI,eAAM,EAAE,CAAC;AAEb,KAAK,oBAClB,OAAwB,EACxB,KAAK,GAAG,KAAK;IAEb,MAAM,WAAW,GAAG,OAAO,CAAC,WAAW,CAAC;IACxC,MAAM,OAAO,GAAG,OAAO,CAAC,sBAAsB,CAAC,QAAQ,CAAC,WAAW,CAAC,CAAC;IACrE,MAAM,IAAI,GAAG,IAAA,cAAO,EAAC,OAAO,CAAC,IAAI,EAAE,OAAO,CAAC,IAAI,CAAC,CAAC;IACjD,MAAM,cAAc,GAAG,IAAA,+BAAa,EAAC,IAAI,CAAC,CAAC;IAC3C,MAAM,UAAU,GAAG,MAAM,IAAA,yBAAkB,EACzC,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,YAAY,EAAE,EACxC,cAAc,CACf,CAAC;IAEF,MAAM,MAAM,GAAG,MAAM,IAAA,yCAAoB,EAAC,UAAU,CAAC,MAAM,EAAE,OAAO,EAAE,KAAK,CAAC,CAAC;IAE7E,IAAI,CAAC;QACH,MAAM,MAAM,GAAG,MAAM,IAAA,YAAK,EAAC,MAAM,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE;YAC5C,MAAM,QAAQ,GAAG,IAAA,4BAAY,EAAC,MAAM,CAAC,IAAI,CAAC,CAAC;YAC3C,IAAA,uBAAa,EACX,IAAA,gBAAI,EAAC,MAAM,CAAC,KAAK,CAAC,MAAM,EAAE,eAAe,CAAC,EAC1C,IAAI,CAAC,SAAS,CAAC,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC,EACjC,MAAM,CACP,CAAC;YACF,OAAO,CAA6B,CAAC;QACvC,CAAC,CAAC,CAAC;QAEH,OAAO,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE;YAC7B,IAAI,KAAK,EAAE,CAAC;gBACV,MAAM,CAAC,EAAE,CAAC,QAAQ,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC;gBAC3C,MAAM,CAAC,EAAE,CAAC,OAAO,EAAE,GAAG,EAAE;oBACtB,MAAM,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC;oBAC9B,OAAO,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC,CAAC;gBAC7B,CAAC,CAAC,CAAC;YACL,CAAC;iBAAM,CAAC;gBACN,OAAO,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC,CAAC;YAC7B,CAAC;QACH,CAAC,CAAC,CAAC;IACL,CAAC;IAAC,OAAO,EAAE,EAAE,CAAC;QACZ,MAAM,CAAC,KAAK,CAAC,mBAAmB,WAAW,GAAG,CAAC,CAAC;QAChD,MAAM,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC;QACjB,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC;IAC5B,CAAC;AACH,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { BuildExecutorSchema } from './schema';
|
|
2
1
|
import type { ExecutorContext } from '@nx/devkit';
|
|
2
|
+
import type { BuildExecutorSchema } from './schema';
|
|
3
3
|
export default function runExecutor(options: BuildExecutorSchema, context: ExecutorContext): Promise<{
|
|
4
4
|
success: boolean;
|
|
5
5
|
}>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"executor.js","sourceRoot":"","sources":["../../../../../../plugins/roma/src/executors/build/executor.ts"],"names":[],"mappings":";;AAIA,8BAKC;;
|
|
1
|
+
{"version":3,"file":"executor.js","sourceRoot":"","sources":["../../../../../../plugins/roma/src/executors/build/executor.ts"],"names":[],"mappings":";;AAIA,8BAKC;;AARD,4DAA4B;AAGb,KAAK,UAAU,WAAW,CACvC,OAA4B,EAC5B,OAAwB;IAExB,OAAO,IAAA,eAAK,EAAC,OAAO,EAAE,OAAO,CAAC,KAAK,CAAC,CAAC;AACvC,CAAC"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { Plugin } from 'vite';
|
|
1
|
+
import type { Plugin } from 'vite';
|
|
2
2
|
export declare function minifyEs(): Plugin;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"minify.js","sourceRoot":"","sources":["../../../../../../plugins/roma/src/executors/build/minify.ts"],"names":[],"mappings":";;AAGA,4BAsBC;
|
|
1
|
+
{"version":3,"file":"minify.js","sourceRoot":"","sources":["../../../../../../plugins/roma/src/executors/build/minify.ts"],"names":[],"mappings":";;AAGA,4BAsBC;AAzBD,qCAAoC;AAGpC,SAAgB,QAAQ;IACtB,OAAO;QACL,IAAI,EAAE,UAAU;QAChB,WAAW,EAAE;YACX,KAAK,EAAE,MAAM;YACb,KAAK,CAAC,OAAO,CAAC,IAAI,EAAE,KAAK,EAAE,aAAa;gBACtC,IAAI,aAAa,CAAC,MAAM,KAAK,IAAI,EAAE,CAAC;oBAClC,MAAM,SAAS,GAAG,CAAC,CAAC,aAAa,CAAC,SAAS,CAAC;oBAC5C,MAAM,MAAM,GAAG,MAAM,IAAA,mBAAS,EAAC,IAAI,EAAE;wBACnC,gBAAgB,EAAE,IAAI;wBACtB,YAAY,EAAE,IAAI;wBAClB,SAAS;qBACV,CAAC,CAAC;oBACH,OAAO;wBACL,IAAI,EAAE,MAAM,CAAC,IAAI;wBACjB,GAAG,EAAE,SAAS,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI;qBACjD,CAAC;gBACJ,CAAC;gBACD,OAAO,IAAI,CAAC;YACd,CAAC;SACF;KACQ,CAAC;AACd,CAAC"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { Plugin } from 'vite';
|
|
1
|
+
import { type Plugin } from 'vite';
|
|
2
2
|
export declare const normalizeRootForFusionRouter: Plugin;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"normalizeRootForFusion.js","sourceRoot":"","sources":["../../../../../../plugins/roma/src/executors/build/normalizeRootForFusion.ts"],"names":[],"mappings":";;;AAAA,+
|
|
1
|
+
{"version":3,"file":"normalizeRootForFusion.js","sourceRoot":"","sources":["../../../../../../plugins/roma/src/executors/build/normalizeRootForFusion.ts"],"names":[],"mappings":";;;AAAA,+BAAkD;AAErC,QAAA,4BAA4B,GAAW;IAClD,IAAI,EAAE,kCAAkC;IACxC,OAAO,EAAE,KAAK;IACd,MAAM,CAAC,MAAM;QACX,IAAI,OAAO,MAAM,CAAC,IAAI,KAAK,QAAQ,EAAE,CAAC;YACpC,OAAO,EAAE,IAAI,EAAE,IAAA,oBAAa,EAAC,MAAM,CAAC,IAAI,CAAC,EAAE,CAAC;QAC9C,CAAC;IACH,CAAC;CACF,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { PromiseExecutor } from '@nx/devkit';
|
|
2
|
-
import { ComponentTestExecutorSchema } from './schema';
|
|
1
|
+
import type { PromiseExecutor } from '@nx/devkit';
|
|
2
|
+
import type { ComponentTestExecutorSchema } from './schema';
|
|
3
3
|
declare const runExecutor: PromiseExecutor<ComponentTestExecutorSchema>;
|
|
4
4
|
export default runExecutor;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const tslib_1 = require("tslib");
|
|
4
|
-
const path_1 = require("path");
|
|
5
4
|
const node_child_process_1 = require("node:child_process");
|
|
6
5
|
const node_util_1 = require("node:util");
|
|
6
|
+
const path_1 = require("path");
|
|
7
7
|
const exec = (0, node_util_1.promisify)(node_child_process_1.exec);
|
|
8
8
|
const runExecutor = async (options, context) => {
|
|
9
9
|
const cypress = await Promise.resolve().then(() => tslib_1.__importStar(require('cypress')));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"executor.js","sourceRoot":"","sources":["../../../../../../plugins/roma/src/executors/component-test/executor.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"executor.js","sourceRoot":"","sources":["../../../../../../plugins/roma/src/executors/component-test/executor.ts"],"names":[],"mappings":";;;AAAA,2DAAoD;AACpD,yCAAsC;AAGtC,+BAA4B;AAG5B,MAAM,IAAI,GAAG,IAAA,qBAAS,EAAC,yBAAM,CAAC,CAAC;AAE/B,MAAM,WAAW,GAAiD,KAAK,EACrE,OAAO,EACP,OAAO,EACP,EAAE;IACF,MAAM,OAAO,GAAG,gEAAa,SAAS,GAAC,CAAC;IACxC,MAAM,EAAE,WAAW,EAAE,sBAAsB,EAAE,IAAI,EAAE,GAAG,OAAO,CAAC;IAC9D,MAAM,OAAO,GAAG,IAAA,WAAI,EAAC,IAAI,EAAE,sBAAsB,CAAC,QAAQ,CAAC,WAAW,CAAC,CAAC,IAAI,CAAC,CAAC;IAC9E,IAAI,OAAO,GAAG,IAAI,CAAC;IACnB,MAAM,MAAM,GAAG;QACb,OAAO,EAAE,OAAO;QAChB,KAAK,EAAE,OAAO,CAAC,KAAK;QACpB,WAAW,EAAE,WAAoB;KAClC,CAAC;IACF,IAAI,CAAC;QACH,MAAM,OAAO,GAAG,MAAM,CAAC,OAAO,CAAC,KAAK;YAClC,CAAC,CAAC,OAAO,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vite';
|
|
2
1
|
import type { ExecutorContext } from '@nx/devkit';
|
|
2
|
+
import { type UserConfig } from 'vite';
|
|
3
3
|
export declare const createRomaViteConfig: (config: UserConfig, context: ExecutorContext, watch?: boolean, hmrPort?: number) => Promise<UserConfig>;
|
|
@@ -2,19 +2,18 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.createRomaViteConfig = void 0;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
|
-
|
|
5
|
+
const nx_tsconfig_paths_plugin_1 = require("@nx/vite/plugins/nx-tsconfig-paths.plugin");
|
|
6
|
+
const plugin_react_1 = tslib_1.__importDefault(require("@vitejs/plugin-react"));
|
|
7
|
+
const path_1 = require("path");
|
|
6
8
|
const vite_1 = require("vite");
|
|
9
|
+
const vite_plugin_checker_1 = tslib_1.__importDefault(require("vite-plugin-checker"));
|
|
7
10
|
const vite_plugin_environment_1 = tslib_1.__importDefault(require("vite-plugin-environment"));
|
|
8
|
-
const path_1 = require("path");
|
|
9
|
-
const plugin_react_1 = tslib_1.__importDefault(require("@vitejs/plugin-react"));
|
|
10
|
-
const logger_1 = require("./utils/logger");
|
|
11
|
-
const nx_tsconfig_paths_plugin_1 = require("@nx/vite/plugins/nx-tsconfig-paths.plugin");
|
|
12
11
|
const minify_1 = require("./build/minify");
|
|
13
|
-
const vite_plugin_checker_1 = tslib_1.__importDefault(require("vite-plugin-checker"));
|
|
14
|
-
const get_version_1 = require("./utils/get-version");
|
|
15
12
|
const normalizeRootForFusion_1 = require("./build/normalizeRootForFusion");
|
|
16
|
-
const parse_csp_1 = require("./utils/csp/parse-csp");
|
|
17
13
|
const csp_check_plugin_1 = require("./utils/csp/csp-check-plugin");
|
|
14
|
+
const parse_csp_1 = require("./utils/csp/parse-csp");
|
|
15
|
+
const get_version_1 = require("./utils/get-version");
|
|
16
|
+
const logger_1 = require("./utils/logger");
|
|
18
17
|
const createRomaViteConfig = async (config, context, watch = false, hmrPort = 42000) => {
|
|
19
18
|
var _a;
|
|
20
19
|
const isServe = context.targetName === 'serve';
|
|
@@ -90,9 +89,7 @@ const createRomaViteConfig = async (config, context, watch = false, hmrPort = 42
|
|
|
90
89
|
plugins.push((0, minify_1.minifyEs)());
|
|
91
90
|
}
|
|
92
91
|
if (options.typeCheck) {
|
|
93
|
-
plugins.push(
|
|
94
|
-
// @ts-ignore
|
|
95
|
-
(0, vite_plugin_checker_1.default)({
|
|
92
|
+
plugins.push((0, vite_plugin_checker_1.default)({
|
|
96
93
|
typescript: {
|
|
97
94
|
root: (0, path_1.resolve)(context.root, project.root),
|
|
98
95
|
tsconfigPath: 'tsconfig.app.json',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create-vite-config.js","sourceRoot":"","sources":["../../../../../plugins/roma/src/executors/create-vite-config.ts"],"names":[],"mappings":";;;;
|
|
1
|
+
{"version":3,"file":"create-vite-config.js","sourceRoot":"","sources":["../../../../../plugins/roma/src/executors/create-vite-config.ts"],"names":[],"mappings":";;;;AACA,wFAA0E;AAC1E,gFAAyC;AAEzC,+BAAqC;AACrC,+BAMc;AACd,sFAA0C;AAC1C,8FAA8C;AAC9C,2CAA0C;AAC1C,2EAA8E;AAE9E,mEAAoE;AACpE,qDAA0D;AAC1D,qDAAiD;AACjD,2CAAwC;AAMjC,MAAM,oBAAoB,GAAG,KAAK,EACvC,MAAkB,EAClB,OAAwB,EACxB,KAAK,GAAG,KAAK,EACb,OAAO,GAAG,KAAK,EACf,EAAE;;IACF,MAAM,OAAO,GAAG,OAAO,CAAC,UAAU,KAAK,OAAO,CAAC;IAC/C,MAAM,WAAW,GAAG,OAAO,CAAC,WAAW,CAAC;IACxC,MAAM,OAAO,GAAG,OAAO,CAAC,sBAAsB,CAAC,QAAQ,CAAC,WAAW,CAAC,CAAC;IACrE,MAAM,aAAa,GAAG,OAAO,CAAC,IAAI,CAAC;IACnC,MAAM,WAAW,GAAG,OAAO,CAAC,OAAO,CAAC,KAAK,CAAC;IAC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E,IAAA,cAAO,EAAC,aAAa,EAAE,UAAU,CAAC;YAC1C,KAAK,EAAE,KAAK;gBACV,CAAC,CAAC;oBACE,WAAW,EAAE,IAAI;iBAClB;gBACH,CAAC,CAAC,SAAS;SACd;QACD,OAAO,EAAE;YACP,IAAA,sBAAK,GAAE;YACP,IAAA,wCAAa,GAAE;YACf,IAAA,iCAAO,EAAC;gBACN,QAAQ,EAAE,KAAK,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,CAAC,aAAa;aAC/C,CAAC;YACF,GAAG,OAAO;SACX;KACY,CAAC;IAChB,OAAO,IAAA,mBAAY,EAAC,IAAA,kBAAW,EAAC,MAAM,EAAE,UAAU,CAAC,CAAC,CAAC;AACvD,CAAC,CAAC;AAhJW,QAAA,oBAAoB,wBAgJ/B"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { ExecutorContext } from '@nx/devkit';
|
|
1
|
+
import type { ExecutorContext } from '@nx/devkit';
|
|
2
2
|
export declare const executorContext: ExecutorContext;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.BASELINE_CONFIG_PATH = exports.BIOME_VERSION = void 0;
|
|
4
|
+
exports.resolveBiomeBin = resolveBiomeBin;
|
|
5
|
+
const node_module_1 = require("node:module");
|
|
6
|
+
const node_path_1 = require("node:path");
|
|
7
|
+
exports.BIOME_VERSION = '2.6.9';
|
|
8
|
+
// src/executors/lint -> plugin root (same layout in source and in dist/plugins/roma)
|
|
9
|
+
exports.BASELINE_CONFIG_PATH = (0, node_path_1.join)(__dirname, '..', '..', '..', 'biome-baseline.json');
|
|
10
|
+
function resolveBiomeBin() {
|
|
11
|
+
try {
|
|
12
|
+
return (0, node_module_1.createRequire)(__filename).resolve('@biomejs/biome/bin/biome');
|
|
13
|
+
}
|
|
14
|
+
catch (_a) {
|
|
15
|
+
throw new Error(`Could not resolve @biomejs/biome@${exports.BIOME_VERSION}. Reinstall @equinor/roma-nx-plugin so its dependencies are installed.`);
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
//# sourceMappingURL=biome.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"biome.js","sourceRoot":"","sources":["../../../../../../plugins/roma/src/executors/lint/biome.ts"],"names":[],"mappings":";;;AAcA,0CAQC;AAtBD,6CAA4C;AAC5C,yCAAiC;AAEpB,QAAA,aAAa,GAAG,OAAO,CAAC;AAErC,qFAAqF;AACxE,QAAA,oBAAoB,GAAG,IAAA,gBAAI,EACtC,SAAS,EACT,IAAI,EACJ,IAAI,EACJ,IAAI,EACJ,qBAAqB,CACtB,CAAC;AAEF,SAAgB,eAAe;IAC7B,IAAI,CAAC;QACH,OAAO,IAAA,2BAAa,EAAC,UAAU,CAAC,CAAC,OAAO,CAAC,0BAA0B,CAAC,CAAC;IACvE,CAAC;IAAC,WAAM,CAAC;QACP,MAAM,IAAI,KAAK,CACb,oCAAoC,qBAAa,wEAAwE,CAC1H,CAAC;IACJ,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { ProjectGraph } from '@nx/devkit';
|
|
2
|
+
export type DepConstraint = {
|
|
3
|
+
sourceTag: string;
|
|
4
|
+
onlyDependOnLibsWithTags: Array<string>;
|
|
5
|
+
};
|
|
6
|
+
export type BoundaryViolation = {
|
|
7
|
+
source: string;
|
|
8
|
+
sourceTags: Array<string>;
|
|
9
|
+
target: string;
|
|
10
|
+
targetTags: Array<string>;
|
|
11
|
+
constraint: DepConstraint;
|
|
12
|
+
};
|
|
13
|
+
export declare function checkBoundaries(projectName: string, graph: ProjectGraph, constraints: Array<DepConstraint>): Array<BoundaryViolation>;
|
|
14
|
+
export declare function formatViolation(violation: BoundaryViolation): string;
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.checkBoundaries = checkBoundaries;
|
|
4
|
+
exports.formatViolation = formatViolation;
|
|
5
|
+
function checkBoundaries(projectName, graph, constraints) {
|
|
6
|
+
var _a;
|
|
7
|
+
if (constraints.length === 0)
|
|
8
|
+
return [];
|
|
9
|
+
const tagsOf = (name) => { var _a, _b; return (_b = (_a = graph.nodes[name]) === null || _a === void 0 ? void 0 : _a.data.tags) !== null && _b !== void 0 ? _b : []; };
|
|
10
|
+
const sourceTags = tagsOf(projectName);
|
|
11
|
+
const applicable = constraints.filter((c) => c.sourceTag === '*' || sourceTags.includes(c.sourceTag));
|
|
12
|
+
if (applicable.length === 0)
|
|
13
|
+
return [];
|
|
14
|
+
// npm packages live in graph.externalNodes, so `in graph.nodes` keeps only workspace projects
|
|
15
|
+
const targets = new Set(((_a = graph.dependencies[projectName]) !== null && _a !== void 0 ? _a : [])
|
|
16
|
+
.map((d) => d.target)
|
|
17
|
+
.filter((t) => t !== projectName && t in graph.nodes));
|
|
18
|
+
const violations = [];
|
|
19
|
+
for (const target of targets) {
|
|
20
|
+
const targetTags = tagsOf(target);
|
|
21
|
+
for (const constraint of applicable) {
|
|
22
|
+
const allowed = constraint.onlyDependOnLibsWithTags.some((tag) => tag === '*' || targetTags.includes(tag));
|
|
23
|
+
if (!allowed) {
|
|
24
|
+
violations.push({
|
|
25
|
+
source: projectName,
|
|
26
|
+
sourceTags,
|
|
27
|
+
target,
|
|
28
|
+
targetTags,
|
|
29
|
+
constraint,
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
return violations;
|
|
35
|
+
}
|
|
36
|
+
function formatViolation(violation) {
|
|
37
|
+
const tags = (t) => (t.length ? t.join(', ') : 'no tags');
|
|
38
|
+
const { source, sourceTags, target, targetTags, constraint } = violation;
|
|
39
|
+
return `✖ ${source} (${tags(sourceTags)}) → ${target} (${tags(targetTags)}) violates constraint for "${constraint.sourceTag}" (allowed: ${constraint.onlyDependOnLibsWithTags.join(', ')})`;
|
|
40
|
+
}
|
|
41
|
+
//# sourceMappingURL=boundaries.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"boundaries.js","sourceRoot":"","sources":["../../../../../../plugins/roma/src/executors/lint/boundaries.ts"],"names":[],"mappings":";;AAeA,0CAyCC;AAED,0CAIC;AA/CD,SAAgB,eAAe,CAC7B,WAAmB,EACnB,KAAmB,EACnB,WAAiC;;IAEjC,IAAI,WAAW,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,EAAE,CAAC;IAExC,MAAM,MAAM,GAAG,CAAC,IAAY,EAAiB,EAAE,eAC7C,OAAA,MAAA,MAAA,KAAK,CAAC,KAAK,CAAC,IAAI,CAAC,0CAAE,IAAI,CAAC,IAAI,mCAAI,EAAE,CAAA,EAAA,CAAC;IACrC,MAAM,UAAU,GAAG,MAAM,CAAC,WAAW,CAAC,CAAC;IACvC,MAAM,UAAU,GAAG,WAAW,CAAC,MAAM,CACnC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,SAAS,KAAK,GAAG,IAAI,UAAU,CAAC,QAAQ,CAAC,CAAC,CAAC,SAAS,CAAC,CAC/D,CAAC;IACF,IAAI,UAAU,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,EAAE,CAAC;IAEvC,8FAA8F;IAC9F,MAAM,OAAO,GAAG,IAAI,GAAG,CACrB,CAAC,MAAA,KAAK,CAAC,YAAY,CAAC,WAAW,CAAC,mCAAI,EAAE,CAAC;SACpC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC;SACpB,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,KAAK,WAAW,IAAI,CAAC,IAAI,KAAK,CAAC,KAAK,CAAC,CACxD,CAAC;IAEF,MAAM,UAAU,GAA6B,EAAE,CAAC;IAChD,KAAK,MAAM,MAAM,IAAI,OAAO,EAAE,CAAC;QAC7B,MAAM,UAAU,GAAG,MAAM,CAAC,MAAM,CAAC,CAAC;QAClC,KAAK,MAAM,UAAU,IAAI,UAAU,EAAE,CAAC;YACpC,MAAM,OAAO,GAAG,UAAU,CAAC,wBAAwB,CAAC,IAAI,CACtD,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,KAAK,GAAG,IAAI,UAAU,CAAC,QAAQ,CAAC,GAAG,CAAC,CACjD,CAAC;YACF,IAAI,CAAC,OAAO,EAAE,CAAC;gBACb,UAAU,CAAC,IAAI,CAAC;oBACd,MAAM,EAAE,WAAW;oBACnB,UAAU;oBACV,MAAM;oBACN,UAAU;oBACV,UAAU;iBACX,CAAC,CAAC;YACL,CAAC;QACH,CAAC;IACH,CAAC;IACD,OAAO,UAAU,CAAC;AACpB,CAAC;AAED,SAAgB,eAAe,CAAC,SAA4B;IAC1D,MAAM,IAAI,GAAG,CAAC,CAAgB,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC;IACzE,MAAM,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,EAAE,UAAU,EAAE,UAAU,EAAE,GAAG,SAAS,CAAC;IACzE,OAAO,KAAK,MAAM,KAAK,IAAI,CAAC,UAAU,CAAC,OAAO,MAAM,KAAK,IAAI,CAAC,UAAU,CAAC,8BAA8B,UAAU,CAAC,SAAS,eAAe,UAAU,CAAC,wBAAwB,CAAC,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC;AAC9L,CAAC"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { type PromiseExecutor } from '@nx/devkit';
|
|
2
|
+
import type { LintExecutorSchema } from './schema';
|
|
3
|
+
export declare function hasBiomeConfig(workspaceRoot: string, projectRoot: string): boolean;
|
|
4
|
+
declare const runExecutor: PromiseExecutor<LintExecutorSchema>;
|
|
5
|
+
export default runExecutor;
|