# bfo-ui

Latest version **0.1.2** (published 2022-02-15) · 0 weekly downloads

## Install

```sh
npm install bfo-ui
pnpm add bfo-ui
yarn add bfo-ui
bun add bfo-ui
```

## Health

**Score 10/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; low quality score; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.2 |
| Published | 2022-02-15 |
| First published | 2022-02-15 |
| Weekly downloads | 0 |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 3 |
| Unpacked size | 99.1 KB |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| Maintainers | alice_ww |

## Links

- npm: https://www.npmjs.com/package/bfo-ui
- npm.io page: https://npm.io/package/bfo-ui

## Dependencies (3)

- [vue](https://npm.io/package/vue.md) ^2.6.11
- [core-js](https://npm.io/package/core-js.md) ^3.6.5
- [vue-router](https://npm.io/package/vue-router.md) ^3.2.0

## Recent versions

- 0.1.2 (latest) — 2022-02-15
- 0.1.1 — 2022-02-15
- 0.1.0 — 2022-02-15

## README

# bfo-ui


## 下载
```
npm install bfo-ui
```
## 完整引入
```js
 import Vue from "vue";
 import bfoUi from 'bfo-ui';
 import 'bfo-ui/lib/style/index.css';
 import App from './App.vue';

 Vue.use(bfoUi);

 new Vue({
    el: '#app',
    render: h => h(App)
  });
```
## 按需引入
借助babel-plugin-import，我们可以只引入需要的组件，以达到减小项目体积的目的。
首先安装babel-plugin-import
```
npm install babel-plugin-import -D
```
然后，在根目录下新建.babelrc或者在已有的babel.config.js中添加
```js
module.exports = {
  presets: ["@vue/app"],
  "plugins": [
    [
      "import",
      {
        libraryName: "bfo-ui",
        "camel2DashComponentName": false,//关闭驼峰自动转链式
        "camel2UnderlineComponentName": false,//关闭蛇形自动转链式
        "style": name => {
          const cssname = name.split("/")[2];
          return `bfo-ui/lib/style/${cssname}.css`
        }
      }
    ]
  ]

};
```
接下来，如果你只希望引入部分组件，比如 compontA 和 compontB，那么需要在 main.js 中写入以下内容：
```js
import Vue from "vue";
import App from "./App.vue";
import {compontA} from "bfo-ui";
Vue.use(compontA);

Vue.config.productionTip = false;

new Vue({
  render: (h) => h(App),
}).$mount("#app");
```
## 目前有的组件
- testA
- testB

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