tursa v1.0.0
Intro
This is a simple and small javascript MVC framework for building interfaces.
Installation
npm install --save tursa-js
This assumes that you’re using npm package manager with a module bundler like Webpack or Browserify to consume CommonJS modules.
If you don’t yet use npm or a modern module bundler, and would rather prefer a single-file UMD build that makes tursa.js` available as a global object, you can grab a pre-built version from cdnjs(https://cdnjs.com/libraries tursa-js). We don’t recommend this approach for any serious application, as most of the library complementary to tursa are only available on npm.
Documentation
We're currently expanding and rewriting our docs content - check back soon for more updates!
How Does It Work?
Home file:
<div>
{{message}}
</div>
Index file:
<div o-view>
// rendered view
</div>
<script>
Tursa.AddRoute(controller, route, template);
var route = "home";
var template = "home.html";
function controller(model){
model.message = "Hello World!";
}
</script>
We do a deep dive on how Tursa works in this readthesource episode.
Enjoy!
License
MIT
3 years ago