# intact-shared

> Helpers functions for Intact

Latest version **3.0.46** (published 2026-03-31) · MIT license · 0 weekly downloads

## Install

```sh
npm install intact-shared
pnpm add intact-shared
yarn add intact-shared
bun add intact-shared
```

## Health

**Score 55/100 (C)** — status: active.

Positive: has types; esm support; no vulnerabilities.

Warnings: low downloads.

## Facts

| | |
|---|---|
| Version | 3.0.46 |
| Published | 2026-03-31 |
| First published | 2021-05-10 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 0 |
| Unpacked size | 105.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 58 |
| Author | Javey |
| Maintainers | javey, warrior-bing |

## Links

- npm: https://www.npmjs.com/package/intact-shared
- Repository: https://github.com/Javey/Intact
- Homepage: https://github.com/Javey/Intact#readme
- Issues: https://github.com/Javey/Intact/issues
- npm.io page: https://npm.io/package/intact-shared

## Recent versions

- 3.0.46 (latest) — 2026-03-31
- 3.0.45 (beta) — 2025-11-26
- 3.0.44 — 2025-09-02
- 3.0.43 — 2025-09-01
- 3.0.42 — 2025-08-28
- 3.0.42-beta.1 — 2025-08-05
- 3.0.41 — 2025-07-24
- 3.0.40 — 2025-01-21
- 3.0.39 — 2024-08-15
- 3.0.38 — 2024-08-07
- 3.0.37 — 2024-06-03
- 3.0.36 — 2024-05-23
- 3.0.35 — 2024-05-22
- 3.0.34 — 2024-04-12
- 3.0.33 — 2024-03-15
- … 57 more at https://npm.io/package/intact-shared/versions

## README

<p align="center">
    <a href="https://travis-ci.org/Javey/Intact">
        <img src="https://travis-ci.org/Javey/Intact.svg?branch=master" alt="Build Status">
    </a>
    <br />
    <a href="https://saucelabs.com/u/Intactjs">
        <img src="https://saucelabs.com/browser-matrix/Intactjs.svg" alt="Browser Matrix">
    </a> 
</p>

# Intact

[文档 Documents](http://javey.github.io/Intact/#/document/start)

## 简介

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

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

## 安装

### 通过script标签引入

请通过`npm`、`bower`或者直接到github上下载源码包。其中
[`dist/intact.js`](https://raw.githubusercontent.com/Javey/Intact/master/dist/intact.js)
为UMD方式打包的文件，直接通过script引入会暴露全局变量`Intact`。

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

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

### NPM

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

```bash
npm install intact --save
```

## 使用

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

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

```js
window.app = Intact.mount(App, document.getElementById('app'));
```
## 许可

MIT

---
_Source: https://npm.io/package/intact-shared · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
