-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
13 changed files
with
149 additions
and
196 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,34 @@ | ||
# monorepo-template | ||
|
||
![][license-url] [![Coverage][coverage]][codecov-url] | ||
|
||
[![ docs by dumi][dumi-url]](https://d.umijs.org/) [![Build With father][father-url]](https://github.com/umijs/father/) [![lerna](https://img.shields.io/badge/maintained%20with-lerna-cc00ff.svg)][lerna-url] [![typedoc](https://img.shields.io/badge/API%20by-typedoc-9600ff.svg)](https://typedoc.org/) | ||
|
||
[![Gitmoji][gitmoji]] [gitmoji-url] [![semantic-release][semantic-release]][semantic-release-repo] | ||
|
||
<!-- umi url --> | ||
|
||
[lerna-url]: https://lernajs.io/ | ||
[dumi-url]: https://img.shields.io/badge/docs%20by-dumi-blue | ||
[father-url]: https://img.shields.io/badge/build%20with-father-028fe4.svg | ||
|
||
<!-- badage url --> | ||
|
||
[gitmoji]: https://img.shields.io/badge/gitmoji-%20😜%20😍-FFDD67.svg | ||
[gitmoji-url]: https://gitmoji.carloscuesta.me/ | ||
[semantic-release]: https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg | ||
[semantic-release-repo]: https://github.com/semantic-release/semantic-release | ||
[license-url]: https://img.shields.io/github/license/arvinxx/gitmoji-commit-workflow | ||
|
||
<!-- Github CI --> | ||
|
||
[test-ci]: https://github.com/arvinxx/monorepo-template/workflows/Test%20CI/badge.svg | ||
[release-ci]: https://github.com/arvinxx/monorepo-template/workflows/Release%20CI/badge.svg | ||
[test-ci-url]: https://github.com/arvinxx/monorepo-template/actions?query=workflow%3A%22Test+CI%22 | ||
[deploy-ci-url]: https://github.com/arvinxx/monorepo-template/actions?query=workflow%3A%22Release+CI%22 | ||
[coverage]: https://codecov.io/gh/arvinxx/monorepo-template/branch/master/graph/badge.svg | ||
[codecov-url]: https://codecov.io/gh/arvinxx/monorepo-template/branch/master | ||
|
||
## License | ||
|
||
[MIT](./LICENSE) ® Arvin Xu |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
{ | ||
"presets": [ | ||
"@babel/preset-react", | ||
"@babel/preset-env", | ||
"@babel/preset-typescript" | ||
], | ||
"plugins": [ | ||
[ | ||
"module-resolver", | ||
{ | ||
"root": ["./"], | ||
"alias": { | ||
"@arvinxu/modules-foo": "./src" | ||
} | ||
} | ||
], | ||
"@babel/plugin-transform-react-jsx" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
# @arvinxu/modules-foo | ||
|
||
[![NPM version][version-image]][version-url] [![NPM downloads][download-image]][download-url] | ||
|
||
a commitlint plugin to add gitmoji check rule | ||
|
||
## License | ||
|
||
[MIT](../../LICENSE) ® Arvin Xu | ||
|
||
<!-- npm url --> | ||
|
||
[version-image]: http://img.shields.io/npm/v/@arvinxu/modules-foo.svg?color=deepgreen&label=latest | ||
[version-url]: http://npmjs.org/package/@arvinxu/modules-foo | ||
[download-image]: https://img.shields.io/npm/dm/@arvinxu/modules-foo.svg | ||
[download-url]: https://npmjs.org/package/@arvinxu/modules-foo |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import type { Config } from '@jest/types'; | ||
import base from '../../jest.config'; | ||
|
||
const packageName = '@arvinxu/modules-foo'; | ||
|
||
const root = '<rootDir>/packages/foo'; | ||
|
||
const config: Config.InitialOptions = { | ||
...base, | ||
rootDir: '../..', | ||
roots: [root], | ||
name: packageName, | ||
displayName: packageName, | ||
}; | ||
|
||
export default config; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
import React from 'react'; | ||
import type { FC } from 'react'; | ||
|
||
const Foo: FC = () => { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
exports[`Foo 1`] = ` | ||
<div> | ||
Hello! | ||
</div> | ||
`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import React from 'react'; | ||
import renderer from 'react-test-renderer'; | ||
|
||
import Foo from '@arvinxu/modules-foo'; | ||
|
||
test('Foo', () => { | ||
const component = renderer.create(<Foo />); | ||
const tree = component.toJSON(); | ||
expect(tree).toMatchSnapshot(); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.