@salesforce/templates 66.19.1 → 66.20.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 (27) hide show
  1. package/lib/generators/lightningOutGenerator.d.ts +10 -2
  2. package/lib/generators/lightningOutGenerator.js +93 -24
  3. package/lib/generators/lightningOutGenerator.js.map +1 -1
  4. package/lib/i18n/i18n.d.ts +5 -0
  5. package/lib/i18n/i18n.js +5 -0
  6. package/lib/i18n/i18n.js.map +1 -1
  7. package/lib/templates/lightningout/default/lightningOutApp.xml +7 -0
  8. package/lib/templates/project/angularextapp/_p_/_m_/_w_/_a_/package-lock.json +140 -154
  9. package/lib/templates/project/angularintapp/_p_/_m_/_w_/_a_/package-lock.json +140 -154
  10. package/lib/templates/project/reactexternalapp/_p_/_m_/_w_/_a_/package-lock.json +128 -141
  11. package/lib/templates/project/reactinternalapp/CHANGELOG.md +72 -0
  12. package/lib/templates/project/reactinternalapp/_p_/_m_/_w_/_a_/eslint.config.js +8 -12
  13. package/lib/templates/project/reactinternalapp/_p_/_m_/_w_/_a_/package-lock.json +372 -644
  14. package/lib/templates/project/reactinternalapp/_p_/_m_/_w_/_a_/package.json +6 -6
  15. package/lib/templates/project/reactinternalapp/_p_/_m_/_w_/_a_/src/components/ui/button.tsx +1 -1
  16. package/lib/templates/project/reactinternalapp/_p_/_m_/_w_/_a_/src/components/ui/sonner.tsx +7 -1
  17. package/lib/templates/project/reactinternalapp/package.json +1 -1
  18. package/lib/templates/project/vueinternalapp/_p_/_m_/_w_/_a_/package-lock.json +131 -145
  19. package/lib/templates/uiBundles/angularbasic/package-lock.json +140 -154
  20. package/lib/templates/uiBundles/reactbasic/package-lock.json +128 -141
  21. package/lib/templates/uiBundles/vuebasic/package-lock.json +131 -145
  22. package/lib/utils/lightningOut.d.ts +1 -0
  23. package/lib/utils/lightningOut.js +2 -1
  24. package/lib/utils/lightningOut.js.map +1 -1
  25. package/lib/utils/types.d.ts +31 -6
  26. package/lib/utils/types.js.map +1 -1
  27. package/package.json +2 -2
@@ -3,8 +3,8 @@ import { resolve } from 'node:path';
3
3
  import { fileURLToPath } from 'node:url';
4
4
  import { dirname } from 'node:path';
5
5
  import js from '@eslint/js';
6
- import tseslint from '@typescript-eslint/eslint-plugin';
7
- import tsparser from '@typescript-eslint/parser';
6
+ import { defineConfig } from 'eslint/config';
7
+ import tseslint from 'typescript-eslint';
8
8
  import react from 'eslint-plugin-react';
9
9
  import reactHooks from 'eslint-plugin-react-hooks';
10
10
  import reactRefresh from 'eslint-plugin-react-refresh';
@@ -15,7 +15,7 @@ const __dirname = dirname(fileURLToPath(import.meta.url));
15
15
  const schemaPath = resolve(__dirname, '../../../../../schema.graphql');
16
16
  const schemaExists = existsSync(schemaPath);
17
17
 
18
- const config = [
18
+ const config = defineConfig([
19
19
  // Global ignores
20
20
  {
21
21
  ignores: [
@@ -29,7 +29,7 @@ const config = [
29
29
  {
30
30
  files: ['*.config.{js,ts}', 'vite.config.ts'],
31
31
  languageOptions: {
32
- parser: tsparser,
32
+ parser: tseslint.parser,
33
33
  parserOptions: {
34
34
  ecmaVersion: 'latest',
35
35
  sourceType: 'module',
@@ -41,7 +41,7 @@ const config = [
41
41
  },
42
42
  },
43
43
  plugins: {
44
- '@typescript-eslint': tseslint,
44
+ '@typescript-eslint': tseslint.plugin,
45
45
  },
46
46
  rules: {
47
47
  '@typescript-eslint/no-var-requires': 'off',
@@ -50,6 +50,7 @@ const config = [
50
50
  // Main TypeScript/React files
51
51
  {
52
52
  files: ['**/*.{ts,tsx}'],
53
+ extends: [js.configs.recommended, tseslint.configs.recommended],
53
54
  ignores: [
54
55
  'coverage',
55
56
  'dist',
@@ -61,14 +62,12 @@ const config = [
61
62
  languageOptions: {
62
63
  ecmaVersion: 2020,
63
64
  sourceType: 'module',
64
- parser: tsparser,
65
65
  parserOptions: {
66
66
  ecmaFeatures: {
67
67
  jsx: true,
68
68
  },
69
69
  ecmaVersion: 'latest',
70
70
  sourceType: 'module',
71
- project: './tsconfig.json',
72
71
  },
73
72
  globals: {
74
73
  ...globals.browser,
@@ -81,11 +80,8 @@ const config = [
81
80
  react,
82
81
  'react-hooks': reactHooks,
83
82
  'react-refresh': reactRefresh,
84
- '@typescript-eslint': tseslint,
85
83
  },
86
84
  rules: {
87
- ...js.configs.recommended.rules,
88
- ...tseslint.configs.recommended.rules,
89
85
  ...react.configs.recommended.rules,
90
86
  ...reactHooks.configs.recommended.rules,
91
87
  'react/react-in-jsx-scope': 'off',
@@ -120,7 +116,7 @@ const config = [
120
116
  'src/test/**/*.{ts,tsx}',
121
117
  ],
122
118
  languageOptions: {
123
- parser: tsparser,
119
+ parser: tseslint.parser,
124
120
  globals: {
125
121
  ...globals.browser,
126
122
  ...globals.node,
@@ -132,7 +128,7 @@ const config = [
132
128
  '@typescript-eslint/no-explicit-any': 'off',
133
129
  },
134
130
  },
135
- ];
131
+ ]);
136
132
 
137
133
  // Only add GraphQL rules when schema exists (e.g. after graphql:schema).
138
134
  // In CI or when schema is not checked in, skip so lint succeeds.