@jsenv/file-size-impact 14.0.0 → 14.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.
@@ -0,0 +1,19 @@
1
+ #!/usr/bin/env node
2
+
3
+ import { pathToFileURL } from "node:url"
4
+ import { generateFileSizeReport } from "@jsenv/file-size-impact"
5
+
6
+ const cwdUrl = `${pathToFileURL(process.cwd())}/`
7
+ const argv = process.argv.slice(2)
8
+ const dirname = argv[0] || "dist"
9
+
10
+ await generateFileSizeReport({
11
+ log: true,
12
+ rootDirectoryUrl: cwdUrl,
13
+ trackingConfig: {
14
+ [dirname]: {
15
+ [`${dirname}/**/*`]: true,
16
+ [`${dirname}/**/*.map`]: false,
17
+ },
18
+ },
19
+ })
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@jsenv/file-size-impact",
3
- "version": "14.0.0",
3
+ "version": "14.1.1",
4
4
  "description": "Add files size impact into pull requests",
5
5
  "license": "MIT",
6
6
  "repository": {
7
7
  "type": "git",
8
8
  "url": "https://github.com/jsenv/workflow",
9
- "directory": "packages/jsenv-file-size-impact"
9
+ "directory": "packages/file-size-impact"
10
10
  },
11
11
  "engines": {
12
12
  "node": ">=16.13.0"
@@ -21,6 +21,9 @@
21
21
  },
22
22
  "./*": "./*"
23
23
  },
24
+ "bin": {
25
+ "filesize": "./bin/filesize.mjs"
26
+ },
24
27
  "main": "./src/main.js",
25
28
  "files": [
26
29
  "/src/"
@@ -32,9 +35,9 @@
32
35
  },
33
36
  "dependencies": {
34
37
  "@jsenv/dynamic-import-worker": "1.1.0",
35
- "@jsenv/filesystem": "4.1.9",
36
- "@jsenv/github-pull-request-impact": "1.7.1",
37
- "@jsenv/log": "3.3.3",
38
- "@jsenv/urls": "1.2.8"
38
+ "@jsenv/filesystem": "4.2.3",
39
+ "@jsenv/github-pull-request-impact": "1.7.2",
40
+ "@jsenv/log": "3.3.4",
41
+ "@jsenv/urls": "2.0.0"
39
42
  }
40
43
  }
package/readme.md CHANGED
@@ -97,7 +97,7 @@ _report_file_size_impact.mjs_
97
97
  * This file is executed by file_size_impact.yml GitHub workflow.
98
98
  * - it generates file size report before and after merging a pull request
99
99
  * - Then, it creates or updates a comment in the pull request
100
- * See https://github.com/jsenv/workflow/tree/main/packages/jsenv-file-size-impact#how-it-works
100
+ * See https://github.com/jsenv/workflow/tree/main/packages/file-size-impact#how-it-works
101
101
  */
102
102
 
103
103
  import {
@@ -440,8 +440,8 @@ Read more in [manifestConfig](#manifestConfig) parameter
440
440
 
441
441
  # See also
442
442
 
443
- - [@jsenv/performance-impact](../jsenv-performance-impact): Monitor pull requests impacts but on performance metrics
444
- - [@jsenv/lighthouse-impact](../jsenv-lighthouse-impact): Monitor pull requests impacts but on lighthouse score
443
+ - [@jsenv/performance-impact](../performance-impact): Monitor pull requests impacts but on performance metrics
444
+ - [@jsenv/lighthouse-impact](../lighthouse-impact): Monitor pull requests impacts but on lighthouse score
445
445
 
446
446
  # Note about GitHub workflow paths
447
447
 
@@ -106,7 +106,7 @@ export const reportFileSizeImpactInGitHubPullRequest = async ({
106
106
  })
107
107
  },
108
108
  generatedByLink: {
109
- url: "https://github.com/jsenv/workflow/tree/main/packages/jsenv-file-size-impact",
109
+ url: "https://github.com/jsenv/workflow/tree/main/packages/file-size-impact",
110
110
  text: "@jsenv/file-size-impact",
111
111
  },
112
112
  runLink,