This commit is contained in:
2023-04-15 05:21:48 +08:00
commit b2627a6b62
55 changed files with 57248 additions and 0 deletions

View File

@@ -0,0 +1,19 @@
import { defineConfig } from 'father';
export default defineConfig({
esm: { input: 'src', // 默认编译目录
platform: 'browser', // 默认构建为 Browser 环境的产物
transformer: 'babel', // 默认使用 babel 以提供更好的兼容性
},
extraBabelPlugins: [
[
'babel-plugin-import',
{
libraryName: 'antd',
libraryDirectory: 'es',
style: true,
},
],
],
});

3
packages/bank-hooks/.gitignore vendored Normal file
View File

@@ -0,0 +1,3 @@
/node_modules
/dist
.DS_Store

View File

@@ -0,0 +1,23 @@
# @alipay/antbank-platform-ui
[![NPM version](https://img.shields.io/npm/v/@alipay/antbank-platform-ui.svg?style=flat)](https://npmjs.org/package/@alipay/antbank-platform-ui)
[![NPM downloads](http://img.shields.io/npm/dm/@alipay/antbank-platform-ui.svg?style=flat)](https://npmjs.org/package/@alipay/antbank-platform-ui)
## Install
```bash
$ yarn install
```
```bash
$ npm run dev
$ npm run build
```
## Options
TODO
## LICENSE
MIT

View File

@@ -0,0 +1,32 @@
{
"name": "@lishican/antbank-platform-hooks",
"version": "0.0.4",
"description": "",
"module": "dist/esm/index.js",
"types": "dist/esm/index.d.ts",
"scripts": {
"dev": "father dev",
"build": "father build",
"build:deps": "father prebundle",
"prepublish": "npm run build"
},
"keywords": [],
"authors": [],
"license": "MIT",
"files": [
"dist",
"compiled"
],
"publishConfig": {
"access": "public"
},
"devDependencies": {
"@babel/runtime": "^7.12.5",
"father": "^4.1.8"
},
"peerDependencies": {
"antd": "^5.4.2",
"react": ">=16.9.0",
"react-dom": ">=16.9.0"
}
}

View File

@@ -0,0 +1,4 @@
import useTask from './use-test'
export {
useTask
}

View File

@@ -0,0 +1,8 @@
import { useEffect } from 'react';
const useTask = () => {
useEffect(() => {
console.log('useTask');
}, []);
};
export default useTask;

View File

@@ -0,0 +1,16 @@
{
"compilerOptions": {
"rootDir": "src",
"outDir": "dist",
"strict": true,
"jsx": "preserve",
"target": "esnext",
"module": "esnext",
"moduleResolution": "node",
"allowSyntheticDefaultImports": true,
"experimentalDecorators": true,
"resolveJsonModule": true,
"declaration": true
},
"include": ["src/**/*", "typings/*"]
}

View File

@@ -0,0 +1,23 @@
import { defineConfig } from 'father';
export default defineConfig({
esm: {
input: "src",
platform: "browser",
transformer:"esbuild"
},
extraBabelPlugins: [
[
'babel-plugin-import',
{
libraryName: 'antd',
libraryDirectory: 'es',
style: true,
},
],
],
});

3
packages/bizComponent/.gitignore vendored Normal file
View File

@@ -0,0 +1,3 @@
/node_modules
/dist
.DS_Store

View File

@@ -0,0 +1,23 @@
# @alipay/antbank-platform-ui
[![NPM version](https://img.shields.io/npm/v/@alipay/antbank-platform-ui.svg?style=flat)](https://npmjs.org/package/@alipay/antbank-platform-ui)
[![NPM downloads](http://img.shields.io/npm/dm/@alipay/antbank-platform-ui.svg?style=flat)](https://npmjs.org/package/@alipay/antbank-platform-ui)
## Install
```bash
$ yarn install
```
```bash
$ npm run dev
$ npm run build
```
## Options
TODO
## LICENSE
MIT

View File

@@ -0,0 +1,36 @@
{
"name": "@lishican/antbank-platform-ui",
"version": "0.0.4",
"description": "",
"module": "dist/esm/index.js",
"types": "dist/esm/index.d.ts",
"scripts": {
"dev": "father dev",
"build": "father build",
"build:deps": "father prebundle",
"prepublish": "npm run build"
},
"keywords": [],
"authors": [],
"license": "MIT",
"files": [
"dist",
"compiled"
],
"publishConfig": {
"access": "public"
},
"devDependencies": {
"@babel/runtime": "^7.12.5",
"father": "^4.1.8"
},
"peerDependencies": {
"antd": "^5.4.2",
"react": ">=16.9.0",
"react-dom": ">=16.9.0"
},
"dependencies": {
"@lishican/antbank-platform-hooks": "^0.0.4",
"styled-components": "^5.3.9"
}
}

View File

@@ -0,0 +1,6 @@
.red {
color: red;
display: flex;
justify-content: center;
align-items: center;
}

View File

@@ -0,0 +1,19 @@
import { useTask } from '@lishican/antbank-platform-hooks';
import { Button } from 'antd';
import React from 'react';
import './index.less';
const HelloWorld: React.FC<any> = () => {
useTask();
return (
<div>
<Button type="primary">3332</Button>
<h3 className='red'>2131</h3>
</div>
);
};
export default HelloWorld;

View File

@@ -0,0 +1,16 @@
{
"compilerOptions": {
"rootDir": "src",
"outDir": "dist",
"strict": true,
"jsx": "preserve",
"target": "esnext",
"module": "esnext",
"moduleResolution": "node",
"allowSyntheticDefaultImports": true,
"experimentalDecorators": true,
"resolveJsonModule": true,
"declaration": true
},
"include": ["src/**/*", "typings/*"]
}

View File

@@ -0,0 +1,4 @@
declare module '*.less' {
const styles: { [className: string]: string };
export default styles;
}