@kong-ui-public/entities-routes 3.25.8 → 3.26.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.
Files changed (2) hide show
  1. package/README.md +15 -21
  2. package/package.json +2 -3
package/README.md CHANGED
@@ -16,7 +16,7 @@ Route entity components.
16
16
  - `@kong/kongponents` must be added as a dependency in the host application, globally available via the Vue Plugin installation, and the package's style imports must be added in the app entry file. [See here for instructions on installing Kongponents](https://kongponents.konghq.com/#globally-install-all-kongponents).
17
17
  - `@kong-ui-public/i18n` must be available as a `dependency` in the host application.
18
18
  - `axios` must be installed as a dependency in the host application.
19
- - If you want to enable [Kong's Expressions language](https://developer.konghq.com/gateway/routing/expressions/)-related [features](#expressions-features) in your host app, `@kong-ui-public/expressions` and `monaco-editor` must be installed as dependencies in the host application.
19
+ - If you want to enable [Kong's Expressions language](https://developer.konghq.com/gateway/routing/expressions/)-related [features](#expressions-features) in your host app, `@kong-ui-public/expressions` and `@kong-ui-public/monaco-editor` must be installed as dependencies in the host application.
20
20
 
21
21
  ## Included components
22
22
 
@@ -36,38 +36,32 @@ Install the component in your host application
36
36
  yarn add @kong-ui-public/entities-routes
37
37
  ```
38
38
 
39
- If you want to enable [expressions feature](#expressions-features), you also need to install `devDependencies` in your host application:
39
+ ### Registration
40
40
 
41
- ```sh
42
- yarn add -D vite-plugin-monaco-editor
41
+ Import the component(s) in your host application as well as the package styles
42
+
43
+ ```ts
44
+ import { RouteList, RouteForm, RouteConfigCard } from '@kong-ui-public/entities-routes'
45
+ import '@kong-ui-public/entities-routes/dist/style.css'
43
46
  ```
44
47
 
45
- Enable the `vite-plugin-monaco-editor` plugin. Your Vite config should look like this:
48
+ ## Expressions features
49
+
50
+ This package utilizes `@kong-ui-public/expressions` and `@kong-ui-public/monaco-editor` to support [Kong's Expressions language](https://developer.konghq.com/gateway/routing/expressions/)-related features. You will need to ensure these dependencies are installed in your host application to enable these features.
51
+
52
+ Host applications should also enable the Monaco Editor Vite plugin from `@kong-ui-public/monaco-editor` so Monaco Editor and its web workers are bundled correctly:
46
53
 
47
54
  ```ts
48
- import monacoEditorPlugin from 'vite-plugin-monaco-editor'
55
+ import monaco from '@kong-ui-public/monaco-editor/vite-plugin'
49
56
 
50
57
  export default defineConfig({
51
- // ...
52
58
  plugins: [
53
- monacoEditorPlugin({}),
59
+ monaco({}),
54
60
  ],
55
- // ...
56
61
  })
57
62
  ```
58
63
 
59
- ### Registration
60
-
61
- Import the component(s) in your host application as well as the package styles
62
-
63
- ```ts
64
- import { RouteList, RouteForm, RouteConfigCard } from '@kong-ui-public/entities-routes'
65
- import '@kong-ui-public/entities-routes/dist/style.css'
66
- ```
67
-
68
- ## Expressions features
69
-
70
- This package utilizes `@kong-ui-public/expressions` and `monaco-editor` to support [Kong's Expressions language](https://developer.konghq.com/gateway/routing/expressions/)-related features. You will need to ensure these dependencies are installed in your host application to enable these features.
64
+ For more information on configuring languages, editor features, Shiki languages, and Shiki themes, refer to the [`@kong-ui-public/monaco-editor` Vite plugin docs](../../core/monaco-editor/vite-plugin/README.md).
71
65
 
72
66
  As of now, `<RouteForm.vue />` is the only component with Expressions features(controlled via the `routeFlavor` prop).
73
67
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kong-ui-public/entities-routes",
3
- "version": "3.25.8",
3
+ "version": "3.26.0",
4
4
  "type": "module",
5
5
  "main": "./dist/entities-routes.umd.js",
6
6
  "module": "./dist/entities-routes.es.js",
@@ -35,7 +35,6 @@
35
35
  "@kong/kongponents": "9.63.0",
36
36
  "@types/lodash.isequal": "^4.5.8",
37
37
  "axios": "^1.17.0",
38
- "vite-plugin-monaco-editor": "^1.1.0",
39
38
  "vue": "^3.5.35",
40
39
  "vue-router": "^5.1.0",
41
40
  "@kong-ui-public/i18n": "^2.5.0",
@@ -57,7 +56,7 @@
57
56
  },
58
57
  "dependencies": {
59
58
  "lodash.isequal": "^4.5.0",
60
- "@kong-ui-public/expressions": "^1.6.11"
59
+ "@kong-ui-public/expressions": "^1.7.0"
61
60
  },
62
61
  "scripts": {
63
62
  "dev": "cross-env USE_SANDBOX=true vite",