-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Webpack config in dev and prod include copywebpack for static transla… #1491
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 1 commit
78f87b6
348056e
c31a65a
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -75,11 +75,11 @@ app.use(corsMiddleware); | |
app.options('*', corsMiddleware); | ||
|
||
// Body parser, cookie parser, sessions, serve public assets | ||
|
||
app.use('/translations', Express.static('translations/locales/')); | ||
|
||
app.use(Express.static(path.resolve(__dirname, '../dist/static'), { | ||
maxAge: process.env.STATIC_MAX_AGE || (process.env.NODE_ENV === 'production' ? '1d' : '0') | ||
})); | ||
app.use('/translations', Express.static('translations/locales/')); | ||
|
||
app.use(bodyParser.urlencoded({ limit: '50mb', extended: true })); | ||
app.use(bodyParser.json({ limit: '50mb' })); | ||
app.use(cookieParser()); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this should stay as
'/translations/{{lng}}/translations.json'
, but the static file config inserver/server.js
needs to change...