-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
12 changed files
with
135 additions
and
252 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 |
---|---|---|
|
@@ -13,5 +13,6 @@ tmp/**/* | |
.idea/**/* | ||
coverage | ||
dist/ | ||
types | ||
*.d.ts | ||
!podium.d.ts | ||
.tap |
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,2 @@ | ||
package-lock=false | ||
save-exact=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
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,22 +1,3 @@ | ||
import prettierConfig from 'eslint-config-prettier'; | ||
import prettierPlugin from 'eslint-plugin-prettier/recommended'; | ||
import globals from 'globals'; | ||
import js from '@eslint/js'; | ||
import config from '@podium/eslint-config'; | ||
|
||
export default [ | ||
js.configs.recommended, | ||
prettierConfig, | ||
prettierPlugin, | ||
{ | ||
languageOptions: { | ||
globals: { | ||
...globals.node, | ||
...globals.browser, | ||
global: true, | ||
}, | ||
}, | ||
}, | ||
{ | ||
ignores: ['coverage/*', 'dist/*'], | ||
}, | ||
]; | ||
export default config; |
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,37 +1,12 @@ | ||
import fs from 'node:fs'; | ||
import path from 'node:path'; | ||
|
||
let fixup = path.join(process.cwd(), 'types', 'podium.d.ts'); | ||
let module = path.join(process.cwd(), 'types', 'podlet.d.ts'); | ||
|
||
fs.writeFileSync( | ||
module, | ||
/* ts */ ` | ||
import type { HttpIncoming } from "@podium/utils"; | ||
declare global { | ||
namespace Express { | ||
export interface Locals { | ||
podium: HttpIncoming; | ||
} | ||
export interface Response { | ||
/** | ||
* Calls the send / write method on the \`http.ServerResponse\` object. | ||
* | ||
* When in development mode this method will wrap the provided fragment in a | ||
* default HTML document before dispatching. When not in development mode, this | ||
* method will just dispatch the fragment. | ||
* | ||
* @example | ||
* app.get(podlet.content(), (req, res) => { | ||
* res.podiumSend('<h1>Hello World</h1>'); | ||
* }); | ||
*/ | ||
podiumSend(fragment: string, ...args: unknown[]): Response; | ||
} | ||
} | ||
} | ||
`${fs.readFileSync(fixup, 'utf-8')} | ||
${fs.readFileSync(module, 'utf-8')}`, | ||
'utf-8', | ||
); |
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
This file was deleted.
Oops, something went wrong.
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,3 @@ | ||
export default { | ||
extends: '@podium/semantic-release-config', | ||
}; |
Oops, something went wrong.