@pob/sort-pkg 7.0.0 → 7.1.1

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 CHANGED
@@ -3,6 +3,20 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [7.1.1](https://github.com/christophehurpeau/pob/compare/@pob/sort-pkg@7.1.0...@pob/sort-pkg@7.1.1) (2024-05-05)
7
+
8
+ Note: no notable changes
9
+
10
+ Version bump for dependency: sort-object
11
+
12
+
13
+ ## [7.1.0](https://github.com/christophehurpeau/pob/compare/@pob/sort-pkg@7.0.0...@pob/sort-pkg@7.1.0) (2024-04-21)
14
+
15
+ Note: no notable changes
16
+
17
+
18
+
19
+
6
20
  ## [7.0.0](https://github.com/christophehurpeau/pob/compare/@pob/sort-pkg@6.2.0...@pob/sort-pkg@7.0.0) (2023-12-29)
7
21
 
8
22
 
package/README.md CHANGED
@@ -22,10 +22,10 @@ npm install --save @pob/sort-pkg
22
22
  ## Usage
23
23
 
24
24
  ```js
25
- const fs = require('fs');
26
- const sortPkg = require('@pob/sort-pkg');
25
+ const fs = require("fs");
26
+ const sortPkg = require("@pob/sort-pkg");
27
27
 
28
- const pkg = JSON.parse(fs.readFileSync('package.json', 'utf-8'));
28
+ const pkg = JSON.parse(fs.readFileSync("package.json", "utf-8"));
29
29
  sortPkg(pkg);
30
30
  fs.writeFileSync(JSON.stringify(pkg, null, 2), pkg);
31
31
  ```
package/lib/index.js CHANGED
@@ -1,79 +1,79 @@
1
1
  /* eslint-disable complexity */
2
2
 
3
- import sortObject from '@pob/sort-object';
3
+ import sortObject from "@pob/sort-object";
4
4
 
5
5
  export default function sortPkg(pkg) {
6
6
  sortObject(pkg, [
7
7
  /* information on the package */
8
- 'name',
9
- 'private',
10
- 'version',
11
- 'description',
12
- 'keywords',
13
- 'author',
14
- 'authors',
15
- 'contributors',
16
- 'license',
17
- 'repository',
18
- 'homepage',
19
- 'bugs',
8
+ "name",
9
+ "private",
10
+ "version",
11
+ "description",
12
+ "keywords",
13
+ "author",
14
+ "authors",
15
+ "contributors",
16
+ "license",
17
+ "repository",
18
+ "homepage",
19
+ "bugs",
20
20
  /* package type */
21
- 'type',
22
- /* corepack */ 'packageManager',
21
+ "type",
22
+ /* corepack */ "packageManager",
23
23
  /* package env and configuration */
24
- 'engines',
25
- 'engineStrict',
26
- 'os',
27
- 'cpu',
28
- 'libc',
29
- 'sideEffects',
30
- 'config',
24
+ "engines",
25
+ "engineStrict",
26
+ "os",
27
+ "cpu",
28
+ "libc",
29
+ "sideEffects",
30
+ "config",
31
31
  /* workspaces */
32
- 'workspaces',
32
+ "workspaces",
33
33
  /* exports */
34
- 'bin',
35
- 'main',
36
- 'types',
37
- 'typesVersions',
38
- 'jsnext:main',
39
- 'module',
40
- 'browser',
41
- 'browserify',
42
- 'exports',
43
- 'style', // https://stackoverflow.com/questions/32037150/style-field-in-package-json
34
+ "bin",
35
+ "main",
36
+ "types",
37
+ "typesVersions",
38
+ "jsnext:main",
39
+ "module",
40
+ "browser",
41
+ "browserify",
42
+ "exports",
43
+ "style", // https://stackoverflow.com/questions/32037150/style-field-in-package-json
44
44
  /* documentation */
45
- 'man',
45
+ "man",
46
46
  /* publish */
47
- 'publishConfig',
48
- 'directories',
49
- 'files',
47
+ "publishConfig",
48
+ "directories",
49
+ "files",
50
50
  /* scripts */
51
- 'scripts',
51
+ "scripts",
52
52
  /* dependencies configs */
53
- 'babel',
54
- 'browserslist',
55
- 'commitlint',
56
- 'eslintConfig',
57
- 'husky',
58
- 'jest',
59
- 'lint-staged',
60
- 'pob',
61
- 'prettier',
62
- 'stylelint',
53
+ "babel",
54
+ "browserslist",
55
+ "commitlint",
56
+ "eslintConfig",
57
+ "husky",
58
+ "jest",
59
+ "lint-staged",
60
+ "pob",
61
+ "prettier",
62
+ "stylelint",
63
63
  /* dependencies */
64
- 'overrides',
65
- 'overridesExplained',
66
- 'resolutions',
67
- 'resolutionsExplained',
68
- 'peerDependencies',
69
- 'peerDependenciesMeta',
70
- 'devPeerDependencies',
71
- 'dependencies',
72
- 'devDependencies',
73
- 'dependenciesMeta',
74
- 'optionalDependencies',
75
- 'bundledDependencies',
76
- 'bundleDependencies',
64
+ "overrides",
65
+ "overridesExplained",
66
+ "resolutions",
67
+ "resolutionsExplained",
68
+ "peerDependencies",
69
+ "peerDependenciesMeta",
70
+ "devPeerDependencies",
71
+ "dependencies",
72
+ "devDependencies",
73
+ "dependenciesMeta",
74
+ "optionalDependencies",
75
+ "bundledDependencies",
76
+ "bundleDependencies",
77
77
  ]);
78
78
 
79
79
  if (pkg.scripts) sortObject(pkg.scripts);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pob/sort-pkg",
3
- "version": "7.0.0",
3
+ "version": "7.1.1",
4
4
  "description": "sort package.json",
5
5
  "keywords": [],
6
6
  "author": "Christophe Hurpeau <christophe@hurpeau.com> (https://christophe.hurpeau.com)",
@@ -34,6 +34,6 @@
34
34
  "pob": {},
35
35
  "prettier": "@pob/root/prettier-config",
36
36
  "dependencies": {
37
- "@pob/sort-object": "6.2.1"
37
+ "@pob/sort-object": "6.3.1"
38
38
  }
39
39
  }