-
-
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.
chore: move copy templates to root of the package
- Loading branch information
Showing
16 changed files
with
105 additions
and
0 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 |
---|---|---|
@@ -0,0 +1 @@ | ||
export { {{name}} } from './{{name}}'; |
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 @@ | ||
.{{name}} {} |
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 @@ | ||
import React from 'react'; | ||
{{#propTypes}} | ||
import PropTypes from 'prop-types'; | ||
{{/propTypes}} | ||
{{#style}} | ||
import {{#cssModules}}classes from {{/cssModules}}'./style.{{style}}'; | ||
{{/style}} | ||
|
||
export class {{name}} extends React.Component { | ||
render() { | ||
return <div className={{#cssModules}}{classes.{{name}}}{{/cssModules}}{{^cssModules}}"{{name}}"{{/cssModules}}>{{name}} works!</div>; | ||
} | ||
} | ||
{{#propTypes}} | ||
|
||
{{name}}.propTypes = { | ||
className: PropTypes.string, | ||
}; | ||
{{/propTypes}} |
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 { render } from '@testing-library/react'; | ||
import { {{name}} } from './{{name}}'; | ||
|
||
describe('{{name}}', () => { | ||
it('should match snapshot', () => { | ||
const { getByText } = render(<{{name}} />); | ||
const linkElement = getByText(/{{name}} works!/i); | ||
expect(linkElement).toBeInTheDocument(); | ||
}); | ||
}); |
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 @@ | ||
export { {{name}} } from './{{name}}'; |
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 @@ | ||
.{{name}} {} |
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 @@ | ||
{{#propTypes}} | ||
import PropTypes from 'prop-types'; | ||
{{/propTypes}} | ||
{{#style}} | ||
import {{#cssModules}}classes from {{/cssModules}}'./style.{{style}}'; | ||
{{/style}} | ||
|
||
export const {{name}} = () => { | ||
return <div className={{#cssModules}}{classes.{{name}}}{{/cssModules}}{{^cssModules}}"{{name}}"{{/cssModules}}>{{name}} works!</div>; | ||
}; | ||
{{#propTypes}} | ||
|
||
{{name}}.propTypes = { | ||
className: PropTypes.string, | ||
}; | ||
{{/propTypes}} |
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 { render } from '@testing-library/react'; | ||
import { {{name}} } from './{{name}}'; | ||
|
||
describe('{{name}}', () => { | ||
it('should match snapshot', () => { | ||
const { getByText } = render(<{{name}} />); | ||
const linkElement = getByText(/{{name}} works!/i); | ||
expect(linkElement).toBeInTheDocument(); | ||
}); | ||
}); |
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 @@ | ||
export { {{name}} } from './{{name}}'; |
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 @@ | ||
.{{name}} {} |
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 { render } from '@testing-library/react'; | ||
import { {{name}} } from './{{name}}'; | ||
|
||
describe('{{name}}', () => { | ||
it('should match snapshot', () => { | ||
const { getByText } = render(<{{name}} />); | ||
const linkElement = getByText(/{{name}} works!/i); | ||
expect(linkElement).toBeInTheDocument(); | ||
}); | ||
}); |
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,12 @@ | ||
import React from 'react'; | ||
{{#style}} | ||
import {{#cssModules}}classes from {{/cssModules}}'./style.{{style}}'; | ||
{{/style}} | ||
|
||
interface {{name}}Props {} | ||
|
||
export class {{name}} extends React.Component<{{name}}Props> { | ||
render() { | ||
return <div className={{#cssModules}}{classes.{{name}}}{{/cssModules}}{{^cssModules}}"{{name}}"{{/cssModules}}>{{name}} works!</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 @@ | ||
export { {{name}} } from './{{name}}'; |
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 @@ | ||
.{{name}} {} |
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 { render } from '@testing-library/react'; | ||
import { {{name}} } from './{{name}}'; | ||
|
||
describe('{{name}}', () => { | ||
it('should match snapshot', () => { | ||
const { getByText } = render(<{{name}} />); | ||
const linkElement = getByText(/{{name}} works!/i); | ||
expect(linkElement).toBeInTheDocument(); | ||
}); | ||
}); |
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 type React from 'react'; | ||
{{#style}} | ||
import {{#cssModules}}classes from {{/cssModules}}'./style.{{style}}'; | ||
{{/style}} | ||
|
||
interface {{name}}Props {} | ||
|
||
export const {{name}}: React.FC<{{name}}Props> = () => { | ||
return <div className={{#cssModules}}{classes.{{name}}}{{/cssModules}}{{^cssModules}}"{{name}}"{{/cssModules}}>{{name}} works!</div>; | ||
}; |