Skip to content

A simple example to reproduce the Vue.js, AngularJs(or Angular2+), or React.js variable replacement system. In this case, it's can be used to change the language of the website with many `json` files.

Notifications You must be signed in to change notification settings

tfSheol/Vue.js-or-not-Vue.js

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Vue.js or not Vue.js...

A simple example to reproduce the Vue.js, AngularJs(or Angular2+), or React.js variable replacement system. In this case, it's can be used to change the language of the website with many json files.

let vue = new Vue();
vue.getValues("assets/values.json").then(result => vue.replaceTemplateValue(result));

Start example project

$ npm install
$ npm run serve

Dependencies

http-server="^0.12.3"

Json example

{
    "_home.title": "Vue.js or not Vue.js...",
    "test.message": "a test message",
    "test.bis": "A second test Message",
    "lorem.1": "Lorem ipsum ...",
    "missing.in.html": "nothing to show here"
}

About

A simple example to reproduce the Vue.js, AngularJs(or Angular2+), or React.js variable replacement system. In this case, it's can be used to change the language of the website with many `json` files.

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published