mirror of
https://github.com/strapi/strapi.git
synced 2025-09-16 03:48:22 +00:00
Disable locales by default and remove useless configurations
This commit is contained in:
parent
fa39bcd988
commit
c59b16a38f
@ -6,20 +6,5 @@
|
||||
"path": "favicon.ico",
|
||||
"maxAge": 86400000
|
||||
},
|
||||
"prefix": "",
|
||||
"jsonapi": {
|
||||
"enabled": false,
|
||||
"keyForAttribute": "dash-case",
|
||||
"ignoreRelationshipData": true,
|
||||
"includedRelationshipData": true,
|
||||
"paginate": 10,
|
||||
"showVersion": false
|
||||
},
|
||||
"graphql": {
|
||||
"enabled": false,
|
||||
"graphiql": false,
|
||||
"pretty": true,
|
||||
"usefulQueries": false,
|
||||
"ignoreMutations": true
|
||||
}
|
||||
"prefix": ""
|
||||
}
|
||||
|
@ -1,5 +1,6 @@
|
||||
{
|
||||
"i18n": {
|
||||
"enabled": false,
|
||||
"defaultLocale": "en_US",
|
||||
"modes": [
|
||||
"query",
|
||||
|
@ -41,7 +41,7 @@ module.exports = strapi => {
|
||||
*/
|
||||
|
||||
initialize: cb => {
|
||||
if (_.isPlainObject(strapi.config.i18n) && !_.isEmpty(strapi.config.i18n)) {
|
||||
if (_.isPlainObject(strapi.config.i18n) && !_.isEmpty(strapi.config.i18n) && _.get(strapi.config, 'i18n.enabled') !== false) {
|
||||
strapi.middlewares.locale(strapi.app);
|
||||
strapi.app.use(strapi.middlewares.convert(strapi.middlewares.i18n(strapi.app, {
|
||||
directory: path.resolve(strapi.config.appPath, strapi.config.paths.config, 'locales'),
|
||||
|
Loading…
x
Reference in New Issue
Block a user