webix-hub / webix-jet

Webix Jet micro framework for Webix UI
67 stars 19 forks source link

Update Locale.ts #9

Closed atoumbre closed 6 years ago

atoumbre commented 7 years ago

Configurable locales directory

mkozhukh commented 7 years ago

Hi,

Actually, the directory can be already reconfigured in webpack's config.

//webpack.config.js
"jet-locales":path.resolve(__dirname, "sources/locales")

https://github.com/webix-hub/jet-start/blob/master/webpack.config.js#L42

You can point this path to any custom folder. Is there some scenario when you prefer to configure this value directly in app's config ?

atoumbre commented 7 years ago

Hello Maksim.

Thanks for feedback. Yes, if there is two or tree sub-app in the same project, configurable locales directory may save time.

2017-10-20 11:44 GMT+00:00 Maksim Kozhukh notifications@github.com:

Hi,

Actually, the directory can be already reconfigured in webpack's config.

//webpack.config.js "jet-locales":path.resolve(__dirname, "sources/locales")

https://github.com/webix-hub/jet-start/blob/master/webpack.config.js#L42

You can point this path to any custom folder. Is there some scenario when you prefer to configure this value directly in app's config ?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/webix-hub/jet-core/pull/9#issuecomment-338183529, or mute the thread https://github.com/notifications/unsubscribe-auth/AJyUHY6yamCsr_FQ5yMwaoEYIn95ZFLZks5suIeagaJpZM4P_Pf5 .

mkozhukh commented 6 years ago

Webix Jet 1.3.3 support a similar syntax

app.use(plugins.Locale, { path:"some"})

where path is subfolder (subpath) inside of jet-locale folder

atoumbre commented 6 years ago

Nice. Thanks for keep improving Webix.