Code Monkey home page Code Monkey logo

intact's Introduction

Build Status
Browser Matrix

Intact

文档 Documents

简介

Intact作为一个可继承,并且拥有强逻辑模板的前端MVVM框架,有着如下特色:

  1. 充分利用组合与继承的**,来最高限度地复用代码
  2. 同时支持数据驱动和组件实例化调用,来最便捷地实现功能
  3. 强逻辑模板,赋予模板更多功能和职责,来完成业务逻辑和表现逻辑分离

安装

通过script标签引入

请通过npmbower或者直接到github上下载源码包。其中 dist/intact.js 为UMD方式打包的文件,直接通过script引入会暴露全局变量Intact

<script src="/path/to/intact.js"></script>

<!-- 或者通过cdn -->
<script src="//unpkg.com/intact"></script>

NPM

在大型项目中,一般都会使用webpack构建,通过npm包管理器来管理项目依赖。

npm install intact --save

使用

var App = Intact.extend({
    defaults: {
        name: 'Intact'
    },
    template: '<div>Hello {self.get("name")}!</div>'
});

通过Intact.mount方法,可以将该组件挂载到指定元素下。

window.app = Intact.mount(App, document.getElementById('app'));

许可

MIT

intact's People

Contributors

javey avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.