Skip to content

Conversation

@ddbeck
Copy link
Collaborator

@ddbeck ddbeck commented Jul 9, 2024

Blocked on #1312. From #1312 (comment)

Note to self: after merge, rebase and run npm run test:lint -- --fix.

Copy link
Collaborator Author

@ddbeck ddbeck left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Self-review to highlight relevant bits.

Comment on lines 20 to 33
"dist": "tsx scripts/dist.ts",
"schema-defs": "ts-json-schema-generator --tsconfig ./tsconfig.json --type FeatureData --path ./types.ts --id defs",
"feature-init": "tsx scripts/feature-init.ts",
"format": "npx prettier --write .",
"schema-defs:write": "npm run schema-defs -- --out ./schemas/defs.schema.json",
"test": "npm run test:caniuse -- --quiet && npm run test:schema && npm run test:specs && npm run test:format && npm run test:dist && npm run test --workspaces",
"schema-defs": "ts-json-schema-generator --tsconfig ./tsconfig.json --type FeatureData --path ./types.ts --id defs",
"test:caniuse": "tsx scripts/caniuse.ts",
"test:coverage": "npm run --workspaces test:coverage",
"test:dist": "tsx scripts/dist.ts --check",
"test:format": "prettier --check .",
"test:lint": "npx eslint .",
"test:schema": "tsx scripts/schema.ts",
"test:specs": "tsx scripts/specs.ts",
"test:format": "prettier --check .",
"test:coverage": "npm run --workspaces test:coverage",
"format": "npx prettier --write .",
"feature-init": "tsx scripts/feature-init.ts",
"test": "npm run test:caniuse -- --quiet && npm run test:schema && npm run test:specs && npm run test:format && npm run test:dist && npm run test --workspaces && npm run test:lint",
"update-drafts": "tsx scripts/update-drafts.ts"
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I sorted these, sorry for the chaos diff.

"test:coverage": "npm run --workspaces test:coverage",
"test:dist": "tsx scripts/dist.ts --check",
"test:format": "prettier --check .",
"test:lint": "npx eslint .",
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

New!

"test:coverage": "npm run --workspaces test:coverage",
"format": "npx prettier --write .",
"feature-init": "tsx scripts/feature-init.ts",
"test": "npm run test:caniuse -- --quiet && npm run test:schema && npm run test:specs && npm run test:format && npm run test:dist && npm run test --workspaces && npm run test:lint",
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed!

constructor(id: string, featureData: unknown) {
if (!isFeatureData(featureData)) {
throw `${id} is not valid feature`;
throw new Error(`${id} is not valid feature`);
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Previously thrown as a string, not an error

@ddbeck ddbeck marked this pull request as ready for review July 9, 2024 17:57
@ddbeck ddbeck merged commit 9189c4c into web-platform-dx:main Jul 12, 2024
@ddbeck ddbeck deleted the new-error branch July 12, 2024 11:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants