-
Notifications
You must be signed in to change notification settings - Fork 514
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into chore/add-jsx-rollup-resolver
- Loading branch information
Showing
27 changed files
with
798 additions
and
69 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
{ | ||
"$schema": "https://biomejs.dev/schemas/1.7.1/schema.json", | ||
"formatter": { | ||
"indentStyle": "space" | ||
}, | ||
"linter": { | ||
"enabled": false | ||
}, | ||
"organizeImports": { | ||
"enabled": false | ||
}, | ||
"javascript": { | ||
"formatter": { | ||
"trailingComma": "es5", | ||
"arrowParentheses": "always" | ||
} | ||
}, | ||
"vcs": { | ||
"enabled": true, | ||
"clientKind": "git", | ||
"useIgnoreFile": true | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,12 @@ | ||
import unjs from 'eslint-config-unjs'; | ||
import unjs from "eslint-config-unjs"; | ||
|
||
export default unjs( | ||
{ | ||
ignores: [ | ||
"**/.output", | ||
"**/.nitro", | ||
"**/.netlify", | ||
"**/.nuxt" | ||
], | ||
rules: { | ||
"unicorn/no-null": 0, | ||
"no-undef": 0, | ||
"@typescript-eslint/no-unused-vars": 0, | ||
"unicorn/filename-case": 0, | ||
"unicorn/consistent-function-scoping": 0, | ||
}, | ||
} | ||
); | ||
export default unjs({ | ||
ignores: ["**/.output", "**/.nitro", "**/.netlify", "**/.nuxt"], | ||
rules: { | ||
"unicorn/no-null": 0, | ||
"no-undef": 0, | ||
"@typescript-eslint/no-unused-vars": 0, | ||
"unicorn/filename-case": 0, | ||
"unicorn/consistent-function-scoping": 0, | ||
}, | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
export default defineEventHandler(() => `<h1>${makeGreeting('Nitro')}</h1>`); | ||
export default defineEventHandler(() => `<h1>${makeGreeting("Nitro")}</h1>`); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,9 @@ | ||
export default defineCachedEventHandler(async () => { | ||
await new Promise((resolve) => setTimeout(resolve, 1000)); | ||
return `Response generated at ${new Date().toISOString()} (took 1 second)`; | ||
}, { | ||
shouldBypassCache: (e) => e.node.req.url.includes("preview") | ||
}); | ||
export default defineCachedEventHandler( | ||
async () => { | ||
await new Promise((resolve) => setTimeout(resolve, 1000)); | ||
return `Response generated at ${new Date().toISOString()} (took 1 second)`; | ||
}, | ||
{ | ||
shouldBypassCache: (e) => e.node.req.url.includes("preview"), | ||
} | ||
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,7 @@ | ||
import type { NitroErrorHandler } from "nitropack"; | ||
|
||
export default <NitroErrorHandler>function (error, event) { | ||
const errorHandler: NitroErrorHandler = function (error, event) { | ||
event.res.end("[custom error handler] " + error.stack); | ||
}; | ||
|
||
export default errorHandler; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,3 @@ | ||
|
||
export default eventHandler(async (event) => { | ||
return {}; | ||
}); |
Oops, something went wrong.