-
Notifications
You must be signed in to change notification settings - Fork 1
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
1 parent
ed743db
commit c7e0a28
Showing
7 changed files
with
483 additions
and
289 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,4 @@ | ||
// eslint-disable-next-line n/no-missing-require | ||
let config = require('./node_modules/.embroider/rewritten-app/_babel_config_'); | ||
|
||
module.exports = 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
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 |
---|---|---|
@@ -0,0 +1,59 @@ | ||
import { defineConfig } from "vite"; | ||
import { resolver, hbs, scripts, templateTag, optimizeDeps, compatPrebuild } from "@embroider/vite"; | ||
import { resolve } from "path"; | ||
import { babel } from "@rollup/plugin-babel"; | ||
|
||
const root = "node_modules/.embroider/rewritten-app"; | ||
|
||
import { kolay } from "kolay/vite"; | ||
|
||
export default defineConfig({ | ||
root, | ||
// esbuild in vite does not support decorators | ||
esbuild: false, | ||
cacheDir: resolve("node_modules", ".vite"), | ||
plugins: [ | ||
// Ember standard plugins | ||
hbs(), | ||
templateTag(), | ||
scripts(), | ||
resolver(), | ||
compatPrebuild(), | ||
kolay({ | ||
src: "public/docs", | ||
groups: [ | ||
{ | ||
name: "Runtime", | ||
src: "../ui/docs", | ||
}, | ||
], | ||
packages: ["kolay"], | ||
}), | ||
|
||
babel({ | ||
babelHelpers: "runtime", | ||
|
||
// this needs .hbs because our hbs() plugin above converts them to | ||
// javascript but the javascript still also needs babel, but we don't want | ||
// to rename them because vite isn't great about knowing how to hot-reload | ||
// them if we resolve them to made-up names. | ||
extensions: [".gjs", ".js", ".hbs", ".ts", ".gts"], | ||
}), | ||
], | ||
optimizeDeps: optimizeDeps(), | ||
server: { | ||
port: 4200, | ||
watch: { | ||
ignored: ["!**/node_modules/.embroider/rewritten-app/**"], | ||
}, | ||
}, | ||
build: { | ||
outDir: resolve(process.cwd(), "dist"), | ||
rollupOptions: { | ||
input: { | ||
main: resolve(root, "index.html"), | ||
tests: resolve(root, "tests/index.html"), | ||
}, | ||
}, | ||
}, | ||
}); |
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
Oops, something went wrong.