mirror of
https://github.com/nuxt/nuxt.git
synced 2025-02-16 21:58:19 +00:00
fix(bridge): transpile @nuxt/bridge-edge
(#4070)
This commit is contained in:
parent
9f6eff7511
commit
f39fd9f0a0
@ -5,6 +5,8 @@ export const setupTranspile = () => {
|
|||||||
const nuxt = useNuxt()
|
const nuxt = useNuxt()
|
||||||
|
|
||||||
nuxt.hook('modules:done', () => {
|
nuxt.hook('modules:done', () => {
|
||||||
addModuleTranspiles()
|
addModuleTranspiles({
|
||||||
|
additionalModules: ['@nuxt/bridge-edge']
|
||||||
|
})
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
@ -1,9 +1,14 @@
|
|||||||
import { useNuxt } from '@nuxt/kit'
|
import { useNuxt } from '@nuxt/kit'
|
||||||
|
|
||||||
export const addModuleTranspiles = () => {
|
export interface AddModuleTranspilesOptions {
|
||||||
|
additionalModules?: string[]
|
||||||
|
}
|
||||||
|
|
||||||
|
export const addModuleTranspiles = (opts: AddModuleTranspilesOptions = {}) => {
|
||||||
const nuxt = useNuxt()
|
const nuxt = useNuxt()
|
||||||
|
|
||||||
const modules = [
|
const modules = [
|
||||||
|
...opts.additionalModules || [],
|
||||||
...nuxt.options.buildModules,
|
...nuxt.options.buildModules,
|
||||||
...nuxt.options.modules,
|
...nuxt.options.modules,
|
||||||
...nuxt.options._modules
|
...nuxt.options._modules
|
||||||
|
Loading…
Reference in New Issue
Block a user