ember-codemod-remove-ember-css-modules 0.4.2 → 1.0.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/README.md CHANGED
@@ -228,7 +228,7 @@ The codemod may fail to update complex expressions. Refactor templates to provid
228
228
 
229
229
  ## Compatibility
230
230
 
231
- - Node.js v16 or above
231
+ - Node.js v18 or above
232
232
 
233
233
 
234
234
  ## Contributing
@@ -6,7 +6,6 @@ export function analyzeFilePaths(filePaths) {
6
6
  const { dir, ext, name } = parseFilePath(filePath);
7
7
  const entityName = join(dir, name);
8
8
  if (entities.has(entityName)) {
9
- // eslint-disable-next-line @typescript-eslint/no-non-null-assertion
10
9
  entities.get(entityName).add(ext);
11
10
  return;
12
11
  }
@@ -1,4 +1,4 @@
1
- /* eslint-disable @typescript-eslint/ban-ts-comment, @typescript-eslint/no-unsafe-assignment, @typescript-eslint/no-unsafe-call, @typescript-eslint/no-unsafe-member-access */
1
+ /* eslint-disable @typescript-eslint/ban-ts-comment */
2
2
  import { readFileSync } from 'node:fs';
3
3
  import { join } from 'node:path';
4
4
  import { AST } from '@codemod-utils/ast-javascript';
@@ -10,7 +10,6 @@ function addCssEntryPoint(file, data) {
10
10
  AST.builders.importDeclaration([], AST.builders.literal('./assets/app.css')),
11
11
  AST.builders.noop(),
12
12
  ];
13
- // eslint-disable-next-line @typescript-eslint/no-unsafe-call, @typescript-eslint/no-unsafe-member-access
14
13
  path.value.body.unshift(...nodesToAdd);
15
14
  return false;
16
15
  },
@@ -26,7 +25,6 @@ export function updateAppAppJs(options) {
26
25
  console.warn('WARNING: updateAppAppJs could not find app.{js,ts} in the app folder. Will skip this step.\n');
27
26
  return;
28
27
  }
29
- // eslint-disable-next-line @typescript-eslint/no-non-null-assertion
30
28
  const filePath = filePaths[0];
31
29
  const fileExtension = extname(filePath);
32
30
  const data = {
@@ -26,7 +26,6 @@ function updateDevDependencies(packageJson, options) {
26
26
  const version = getVersion(packageName, options);
27
27
  devDependencies.set(packageName, version);
28
28
  });
29
- // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment
30
29
  packageJson['devDependencies'] = convertToObject(devDependencies);
31
30
  }
32
31
  function updateScripts(packageJson, options) {
@@ -35,7 +34,6 @@ function updateScripts(packageJson, options) {
35
34
  if (project.hasTypeScript) {
36
35
  scripts.set('prelint:types', 'type-css-modules --src app');
37
36
  }
38
- // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment
39
37
  packageJson['scripts'] = convertToObject(scripts);
40
38
  }
41
39
  export function updatePackageJson(options) {
@@ -1,4 +1,4 @@
1
- /* eslint-disable @typescript-eslint/ban-ts-comment, @typescript-eslint/no-non-null-assertion, @typescript-eslint/no-unsafe-argument, @typescript-eslint/no-unsafe-assignment, @typescript-eslint/no-unsafe-call, @typescript-eslint/no-unsafe-member-access */
1
+ /* eslint-disable @typescript-eslint/ban-ts-comment */
2
2
  import { readFileSync } from 'node:fs';
3
3
  import { join } from 'node:path';
4
4
  import { AST } from '@codemod-utils/ast-template';
@@ -1,14 +1,14 @@
1
1
  import { decideVersion } from '@codemod-utils/blueprints';
2
2
  const latestVersions = new Map([
3
- ['@embroider/compat', '3.0.2'],
4
- ['@embroider/core', '3.0.2'],
5
- ['@embroider/webpack', '3.0.0'],
6
- ['autoprefixer', '10.4.14'],
7
- ['embroider-css-modules', '0.1.9'],
8
- ['postcss', '8.4.24'],
3
+ ['@embroider/compat', '3.2.1'],
4
+ ['@embroider/core', '3.2.1'],
5
+ ['@embroider/webpack', '3.1.5'],
6
+ ['autoprefixer', '10.4.15'],
7
+ ['embroider-css-modules', '1.0.0'],
8
+ ['postcss', '8.4.29'],
9
9
  ['postcss-loader', '7.3.3'],
10
- ['type-css-modules', '0.2.2'],
11
- ['webpack', '5.87.0'],
10
+ ['type-css-modules', '1.0.0'],
11
+ ['webpack', '5.88.2'],
12
12
  ]);
13
13
  export function getVersion(packageName, options) {
14
14
  const { project } = options;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ember-codemod-remove-ember-css-modules",
3
- "version": "0.4.2",
3
+ "version": "1.0.0",
4
4
  "description": "Codemod to replace ember-css-modules with embroider-css-modules",
5
5
  "keywords": [
6
6
  "codemod",
@@ -26,29 +26,29 @@
26
26
  "dist"
27
27
  ],
28
28
  "dependencies": {
29
- "@codemod-utils/ast-javascript": "^0.3.2",
30
- "@codemod-utils/ast-template": "^0.3.1",
31
- "@codemod-utils/blueprints": "^0.2.1",
32
- "@codemod-utils/ember-cli-string": "^0.1.1",
33
- "@codemod-utils/files": "^0.5.2",
34
- "@codemod-utils/json": "^0.4.0",
29
+ "@codemod-utils/ast-javascript": "^1.0.0",
30
+ "@codemod-utils/ast-template": "^1.0.0",
31
+ "@codemod-utils/blueprints": "^1.0.0",
32
+ "@codemod-utils/ember-cli-string": "^1.0.0",
33
+ "@codemod-utils/files": "^1.0.0",
34
+ "@codemod-utils/json": "^1.0.0",
35
35
  "yargs": "^17.7.2"
36
36
  },
37
37
  "devDependencies": {
38
- "@codemod-utils/tests": "^0.2.5",
39
- "@sondr3/minitest": "^0.1.1",
40
- "@types/node": "^16.18.39",
38
+ "@codemod-utils/tests": "^1.0.0",
39
+ "@sondr3/minitest": "^0.1.2",
40
+ "@types/node": "^18.17.15",
41
41
  "@types/yargs": "^17.0.24",
42
- "concurrently": "^8.2.0",
43
- "eslint": "^8.46.0",
44
- "prettier": "^3.0.0",
45
- "typescript": "^5.1.6",
42
+ "concurrently": "^8.2.1",
43
+ "eslint": "^8.49.0",
44
+ "prettier": "^3.0.3",
45
+ "typescript": "^5.2.2",
46
46
  "@shared-configs/eslint-config-node": "0.0.0",
47
47
  "@shared-configs/prettier": "0.0.0",
48
48
  "@shared-configs/typescript": "0.0.0"
49
49
  },
50
50
  "engines": {
51
- "node": "16.* || >= 18"
51
+ "node": "18.* || >= 20"
52
52
  },
53
53
  "scripts": {
54
54
  "build": "./build.sh --production",