Fix ALL the spelling

This commit is contained in:
Philipp Krüger 2022-08-17 16:32:05 +02:00
parent b07ab48f56
commit 693f02f4ec
No known key found for this signature in database
GPG Key ID: 8048068BD2ACE7F6
3 changed files with 7 additions and 7 deletions

View File

@ -70,7 +70,7 @@ function localName(name: string) {
: name.slice(16, name.lastIndexOf("$")).replaceAll("$", ".");
}
export async function analyse(elmOutputJsFilePath: string, opts: any) {
export async function analyze(elmOutputJsFilePath: string, opts: any) {
const file = await promisify(FS.readFile)(elmOutputJsFilePath);
const parsed = Esprima.parseScript(file.toString(), { range: true });
const size = parsed.range;
@ -114,7 +114,7 @@ export async function analyse(elmOutputJsFilePath: string, opts: any) {
.map(({ range }) => rangeSize(range))
.reduce((a, b) => a + b, 0);
Console.log(
`Range sum: ${rangeSum} total: ${rangeSize(size)}, analized ${pct(
`Range sum: ${rangeSum} total: ${rangeSize(size)}, analyzed ${pct(
rangeSum,
rangeSize(size)
)}`

View File

@ -1,11 +1,11 @@
#!/usr/bin/env node
import { program } from "commander";
import { analyse } from "./analyse.js";
import { analyze } from "./analyze.js";
program
.name("elmjs-inspector")
.description("Analyse your elm.js file size with this tool.")
.name("elmjs-inspect")
.description("Analyze your elm.js file size with this tool.")
.version("1.0.0");
program
@ -15,7 +15,7 @@ program
)
.argument("<filename>", "The file to analyze")
.action((filename, opts) => {
analyse(filename, opts);
analyze(filename, opts);
});
program.parse();

View File

@ -7,5 +7,5 @@
"outDir": "bin",
"lib": ["ES2021.String"]
},
"files": ["src/analyse.ts", "src/index.ts"]
"files": ["src/analyze.ts", "src/index.ts"]
}