mirror of
https://github.com/Einundzwanzig-Podcast/einundzwanzig-portal.git
synced 2025-12-11 06:46:47 +00:00
34 lines
630 B
JavaScript
34 lines
630 B
JavaScript
const mix = require('laravel-mix')
|
|
const webpack = require('webpack')
|
|
const path = require('path')
|
|
|
|
class NovaExtension {
|
|
name() {
|
|
return 'nova-extension'
|
|
}
|
|
|
|
register(name) {
|
|
this.name = name
|
|
}
|
|
|
|
webpackConfig(webpackConfig) {
|
|
webpackConfig.externals = {
|
|
vue: 'Vue',
|
|
}
|
|
|
|
webpackConfig.resolve.alias = {
|
|
...(webpackConfig.resolve.alias || {}),
|
|
'laravel-nova': path.join(
|
|
__dirname,
|
|
'../../vendor/laravel/nova/resources/js/mixins/packages.js'
|
|
),
|
|
}
|
|
|
|
webpackConfig.output = {
|
|
uniqueName: this.name,
|
|
}
|
|
}
|
|
}
|
|
|
|
mix.extend('nova', new NovaExtension())
|