mirror of
https://github.com/pixelfed/pixelfed.git
synced 2024-11-25 15:55:22 +00:00
Update webpack
This commit is contained in:
parent
1f6d11736a
commit
7217c962bf
4 changed files with 89 additions and 57 deletions
64
resources/assets/js/spa.js
vendored
64
resources/assets/js/spa.js
vendored
|
@ -116,13 +116,13 @@ const ProfileFollowersComponent = () => import(/* webpackChunkName: "profile~fol
|
|||
const ProfileFollowingComponent = () => import(/* webpackChunkName: "profile~following.bundle" */ "./../components/ProfileFollowing.vue");
|
||||
const HashtagComponent = () => import(/* webpackChunkName: "discover~hashtag.bundle" */ "./../components/Hashtag.vue");
|
||||
const NotFoundComponent = () => import(/* webpackChunkName: "error404.bundle" */ "./../components/NotFound.vue");
|
||||
const HelpComponent = () => import(/* webpackChunkName: "help.bundle" */ "./../components/HelpComponent.vue");
|
||||
const KnowledgebaseComponent = () => import(/* webpackChunkName: "kb.bundle" */ "./../components/Knowledgebase.vue");
|
||||
const AboutComponent = () => import(/* webpackChunkName: "about.bundle" */ "./../components/About.vue");
|
||||
const ContactComponent = () => import(/* webpackChunkName: "contact.bundle" */ "./../components/Contact.vue");
|
||||
// const HelpComponent = () => import(/* webpackChunkName: "help.bundle" */ "./../components/HelpComponent.vue");
|
||||
// const KnowledgebaseComponent = () => import(/* webpackChunkName: "kb.bundle" */ "./../components/Knowledgebase.vue");
|
||||
// const AboutComponent = () => import(/* webpackChunkName: "about.bundle" */ "./../components/About.vue");
|
||||
// const ContactComponent = () => import(/* webpackChunkName: "contact.bundle" */ "./../components/Contact.vue");
|
||||
const LanguageComponent = () => import(/* webpackChunkName: "i18n.bundle" */ "./../components/Language.vue");
|
||||
const PrivacyComponent = () => import(/* webpackChunkName: "static~privacy.bundle" */ "./../components/Privacy.vue");
|
||||
const TermsComponent = () => import(/* webpackChunkName: "static~tos.bundle" */ "./../components/Terms.vue");
|
||||
// const PrivacyComponent = () => import(/* webpackChunkName: "static~privacy.bundle" */ "./../components/Privacy.vue");
|
||||
// const TermsComponent = () => import(/* webpackChunkName: "static~tos.bundle" */ "./../components/Terms.vue");
|
||||
const ChangelogComponent = () => import(/* webpackChunkName: "changelog.bundle" */ "./../components/Changelog.vue");
|
||||
|
||||
// import LiveComponent from "./../components/Live.vue";
|
||||
|
@ -234,42 +234,42 @@ const router = new VueRouter({
|
|||
path: "/i/web/direct",
|
||||
component: DirectComponent
|
||||
},
|
||||
{
|
||||
path: "/i/web/kb/:id",
|
||||
name: "kb",
|
||||
component: KnowledgebaseComponent,
|
||||
props: true
|
||||
},
|
||||
// {
|
||||
// path: "/i/web/kb/:id",
|
||||
// name: "kb",
|
||||
// component: KnowledgebaseComponent,
|
||||
// props: true
|
||||
// },
|
||||
{
|
||||
path: "/i/web/hashtag/:id",
|
||||
name: "hashtag",
|
||||
component: HashtagComponent,
|
||||
props: true
|
||||
},
|
||||
{
|
||||
path: "/i/web/help",
|
||||
component: HelpComponent
|
||||
},
|
||||
{
|
||||
path: "/i/web/about",
|
||||
component: AboutComponent
|
||||
},
|
||||
{
|
||||
path: "/i/web/contact",
|
||||
component: ContactComponent
|
||||
},
|
||||
// {
|
||||
// path: "/i/web/help",
|
||||
// component: HelpComponent
|
||||
// },
|
||||
// {
|
||||
// path: "/i/web/about",
|
||||
// component: AboutComponent
|
||||
// },
|
||||
// {
|
||||
// path: "/i/web/contact",
|
||||
// component: ContactComponent
|
||||
// },
|
||||
{
|
||||
path: "/i/web/language",
|
||||
component: LanguageComponent
|
||||
},
|
||||
{
|
||||
path: "/i/web/privacy",
|
||||
component: PrivacyComponent
|
||||
},
|
||||
{
|
||||
path: "/i/web/terms",
|
||||
component: TermsComponent
|
||||
},
|
||||
// {
|
||||
// path: "/i/web/privacy",
|
||||
// component: PrivacyComponent
|
||||
// },
|
||||
// {
|
||||
// path: "/i/web/terms",
|
||||
// component: TermsComponent
|
||||
// },
|
||||
{
|
||||
path: "/i/web/whats-new",
|
||||
component: ChangelogComponent
|
||||
|
|
4
resources/assets/js/stories.js
vendored
Normal file
4
resources/assets/js/stories.js
vendored
Normal file
|
@ -0,0 +1,4 @@
|
|||
Vue.component(
|
||||
'story-viewer',
|
||||
require('./components/StoryViewer.vue').default
|
||||
);
|
29
resources/assets/sass/lib/manrope.scss
vendored
Normal file
29
resources/assets/sass/lib/manrope.scss
vendored
Normal file
|
@ -0,0 +1,29 @@
|
|||
/* latin */
|
||||
@font-face {
|
||||
font-family: 'Manrope';
|
||||
font-style: normal;
|
||||
font-weight: 200;
|
||||
font-display: swap;
|
||||
src: url(/fonts/xn7gYHE41ni1AdIRggexSvfedN4.woff2) format('woff2');
|
||||
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
|
||||
}
|
||||
|
||||
/* latin */
|
||||
@font-face {
|
||||
font-family: 'Manrope';
|
||||
font-style: normal;
|
||||
font-weight: 400;
|
||||
font-display: swap;
|
||||
src: url(/fonts/xn7gYHE41ni1AdIRggexSvfedN4.woff2) format('woff2');
|
||||
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
|
||||
}
|
||||
|
||||
/* latin */
|
||||
@font-face {
|
||||
font-family: 'Manrope';
|
||||
font-style: normal;
|
||||
font-weight: 700;
|
||||
font-display: swap;
|
||||
src: url(/fonts/xn7gYHE41ni1AdIRggexSvfedN4.woff2) format('woff2');
|
||||
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
|
||||
}
|
49
webpack.mix.js
vendored
49
webpack.mix.js
vendored
|
@ -2,7 +2,7 @@ let mix = require('laravel-mix');
|
|||
const fs = require("fs");
|
||||
|
||||
mix.before(() => {
|
||||
fs.rmSync('public/js', { recursive: true, force: true });
|
||||
fs.rmSync('public/js', { recursive: true, force: true });
|
||||
});
|
||||
|
||||
|
||||
|
@ -34,7 +34,6 @@ mix.js('resources/assets/js/app.js', 'public/js')
|
|||
.js('resources/assets/js/spa.js', 'public/js')
|
||||
.js('resources/assets/js/stories.js', 'public/js')
|
||||
.js('resources/assets/js/portfolio.js', 'public/js')
|
||||
.js('resources/assets/js/installer.js', 'public/js')
|
||||
.js('resources/assets/js/admin_invite.js', 'public/js')
|
||||
.js('resources/assets/js/landing.js', 'public/js')
|
||||
.vue({ version: 2 });
|
||||
|
@ -45,31 +44,31 @@ mix.version();
|
|||
const TerserPlugin = require('terser-webpack-plugin');
|
||||
|
||||
mix.options({
|
||||
processCssUrls: false,
|
||||
terser: {
|
||||
parallel: true,
|
||||
terserOptions: {
|
||||
compress: true,
|
||||
output: {
|
||||
comments: false
|
||||
}
|
||||
}
|
||||
}
|
||||
processCssUrls: false,
|
||||
terser: {
|
||||
parallel: true,
|
||||
terserOptions: {
|
||||
compress: true,
|
||||
output: {
|
||||
comments: false
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
mix.webpackConfig({
|
||||
optimization: {
|
||||
providedExports: false,
|
||||
sideEffects: false,
|
||||
usedExports: false,
|
||||
minimize: true,
|
||||
minimizer: [ new TerserPlugin({
|
||||
extractComments: false,
|
||||
})]
|
||||
},
|
||||
output: {
|
||||
chunkFilename: 'js/[name].[chunkhash].js',
|
||||
}
|
||||
optimization: {
|
||||
providedExports: false,
|
||||
sideEffects: false,
|
||||
usedExports: false,
|
||||
minimize: true,
|
||||
minimizer: [ new TerserPlugin({
|
||||
extractComments: false,
|
||||
})]
|
||||
},
|
||||
output: {
|
||||
chunkFilename: 'js/[name].[chunkhash].js',
|
||||
}
|
||||
});
|
||||
mix.autoload({
|
||||
jquery: ['$', 'jQuery', 'window.jQuery']
|
||||
jquery: ['$', 'jQuery', 'window.jQuery']
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue