Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions .oxlintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{
"$schema": "https://raw.githubusercontent.com/oxc-project/oxc/main/npm/oxlint/configuration_schema.json",
"extends": ["./packages/tools/oxc/oxlintrc.json"],
"ignorePatterns": [
"**/dist",
"**/build",
"**/docs",
"**/.tsbuildinfo",
"!scratchpad/**/*",
// TODO: This should be in a nested .oxlintrc.json, but it does not work
// See related issue: https://github.com/oxc-project/oxc/issues/13204
"packages/amp/src/Protobuf/**/*"
],
"jsPlugins": [
"@amp/oxc/oxlint"
],
"overrides": [
{
"files": [
"**/{test,dtslint,examples,benchmark,bundle,scripts,scratchpad}/**"
],
"rules": {
"eslint/no-console": "off",
"effect/no-import-from-barrel-package": "off"
}
}
]
}
6 changes: 6 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"recommendations": [
"oxc.oxc-vscode",
"dprint.dprint"
]
}
47 changes: 21 additions & 26 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,32 +1,27 @@
{
"dprint.path": "node_modules/dprint/dprint",
"typescript.tsdk": "node_modules/typescript/lib",
"typescript.preferences.importModuleSpecifier": "relative",
"typescript.enablePromptUseWorkspaceTsdk": true,
"eslint.format.enable": true,
"eslint.validate": [
"javascript",
"typescript"
],
"[javascript][javascriptreact][typescript][typescriptreact]": {
"editor.formatOnSave": true,
"editor.defaultFormatter": "dbaeumer.vscode-eslint",
"editor.codeActionsOnSave": {
"source.fixAll.eslint": "explicit"
},
"editor.quickSuggestions": {
"other": true,
"comments": false,
"strings": false
},
"editor.acceptSuggestionOnCommitCharacter": true,
"editor.acceptSuggestionOnEnter": "on",
"editor.quickSuggestionsDelay": 10,
"editor.suggestOnTriggerCharacters": true,
"editor.tabCompletion": "off",
"editor.suggest.localityBonus": true,
"editor.suggestSelection": "recentlyUsed",
"editor.wordBasedSuggestions": "matchingDocuments",
"editor.parameterHints.enabled": true,
"files.insertFinalNewline": true,
"editor.formatOnSave": true,
"editor.defaultFormatter": "dprint.dprint",
"editor.formatOnSaveMode": "file",
"editor.codeActionsOnSave": {
"source.fixAll.oxc": "explicit"
},
"editor.quickSuggestions": {
"other": true,
"comments": false,
"strings": false
},
"editor.acceptSuggestionOnCommitCharacter": true,
"editor.acceptSuggestionOnEnter": "on",
"editor.quickSuggestionsDelay": 10,
"editor.suggestOnTriggerCharacters": true,
"editor.tabCompletion": "off",
"editor.suggest.localityBonus": true,
"editor.suggestSelection": "recentlyUsed",
"editor.wordBasedSuggestions": "matchingDocuments",
"editor.parameterHints.enabled": true,
"files.insertFinalNewline": true
}
28 changes: 28 additions & 0 deletions dprint.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{
"$schema": "https://dprint.dev/schemas/v0.json",
"includes": ["**/*.{ts,tsx,js,jsx,json,md}"],
"indentWidth": 2,
"lineWidth": 120,
"newLineKind": "lf",
"typescript": {
"semiColons": "asi",
"quoteStyle": "alwaysDouble",
"trailingCommas": "never",
"operatorPosition": "maintain",
"arrowFunction.useParentheses": "force"
},
"excludes": [
"**/dist",
"**/build",
"**/docs",
"**/coverage",
"!scratchpad/**/*",
// TODO: move to nested configuration if possible
"packages/amp/src/Protobuf/**"
],
"plugins": [
"https://plugins.dprint.dev/typescript-0.93.4.wasm",
"https://plugins.dprint.dev/markdown-0.20.0.wasm",
"https://plugins.dprint.dev/json-0.21.1.wasm"
]
}
155 changes: 0 additions & 155 deletions eslint.config.js

This file was deleted.

15 changes: 5 additions & 10 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,28 +5,23 @@
"scripts": {
"check": "tspc -b tsconfig.json",
"clean": "node scripts/clean.mjs",
"lint": "eslint \"**/{src,test,examples,dtslint}/**/*.{ts,mjs}\"",
"lint-fix": "pnpm lint --fix",
"lint": "oxlint && dprint check",
"lint-fix": "oxlint --fix && dprint fmt",
"test": "vitest"
},
"devDependencies": {
"@effect/eslint-plugin": "^0.3.2",
"@amp/oxc": "workspace:^",
"@effect/language-service": "^0.62.4",
"@effect/platform-node": "^0.104.0",
"@effect/vitest": "^0.27.0",
"@eslint/js": "^9.39.2",
"@types/node": "^25.0.3",
"@vitest/coverage-v8": "^4.0.16",
"@vitest/ui": "^4.0.16",
"dprint": "^0.51.1",
"effect": "^3.19.13",
"eslint": "^9.39.2",
"eslint-import-resolver-typescript": "^4.4.4",
"eslint-plugin-import-x": "^4.16.1",
"eslint-plugin-simple-import-sort": "^12.1.1",
"eslint-plugin-sort-destructure-keys": "^2.0.0",
"eslint-plugin-unused-imports": "^4.3.0",
"glob": "^13.0.0",
"globals": "^16.5.0",
"oxlint": "^1.38.0",
"ts-patch": "^3.3.0",
"typescript": "^5.9.3",
"typescript-eslint": "^8.50.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/amp/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@
**Enabling TypeScript's `erasableSyntaxOnly` Feature**

For some completely absurd reason, the `@bufbuild/protoc-gen-es` plugin does not support generating enum values as anything other than TypeScript enums at this time, so we cannot yet enable this flag.

See the [related `protobuf-es` issue](https://github.com/bufbuild/protobuf-es/issues/1139) for more information.
2 changes: 1 addition & 1 deletion packages/amp/tsconfig.build.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"$schema": "http://json.schemastore.org/tsconfig",
"extends": "./tsconfig.src.jsonc",
"extends": "./tsconfig.src.json",
"compilerOptions": {
"tsBuildInfoFile": ".tsbuildinfo/build.tsbuildinfo",
"outDir": "dist",
Expand Down
2 changes: 1 addition & 1 deletion packages/amp/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"$schema": "http://json.schemastore.org/tsconfig",
"extends": "../../tsconfig.base.jsonc",
"extends": "../../tsconfig.base.json",
"include": [],
"references": [
{ "path": "tsconfig.src.json" },
Expand Down
2 changes: 1 addition & 1 deletion packages/amp/tsconfig.src.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"$schema": "http://json.schemastore.org/tsconfig",
"extends": "../../tsconfig.base.jsonc",
"extends": "../../tsconfig.base.json",
"include": ["src"],
"compilerOptions": {
"tsBuildInfoFile": ".tsbuildinfo/src.tsbuildinfo",
Expand Down
2 changes: 1 addition & 1 deletion packages/amp/tsconfig.test.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"$schema": "http://json.schemastore.org/tsconfig",
"extends": "../../tsconfig.base.jsonc",
"extends": "../../tsconfig.base.json",
"include": ["test"],
"references": [{ "path": "tsconfig.src.json" }],
"compilerOptions": {
Expand Down
Loading