-
Notifications
You must be signed in to change notification settings - Fork 6.5k
chore: updated contributing guidelines, eslint rules and storybook templates #5294
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
ovflowd
merged 17 commits into
nodejs:major/website-redesign
from
ovflowd:chore/normalise-stories-remove-old-stories
Apr 20, 2023
Merged
Changes from 8 commits
Commits
Show all changes
17 commits
Select commit
Hold shift + click to select a range
7915ad7
chore(stories): made stories consistent
ovflowd eb64749
chore(stories): removed old stories
ovflowd 1c7ec68
chore: added new eslint rules to enforce consistency
ovflowd 569ff03
chore: added eslint dependencies
ovflowd 91e3095
chore: linted codeowners
ovflowd 719f31b
feat: updated contributing guidelines
ovflowd 6de80bb
chore: applied eslint on the branch
ovflowd ad984e3
chore: updated affected snapshot
ovflowd b87ed26
Merge branch 'major/website-redesign' into chore/normalise-stories-re…
shanpriyan ea83424
chore: relinted latest changes
ovflowd 328b763
chore: update docs
ovflowd af3924f
Apply suggestions from code review
ovflowd 92a2900
Apply suggestions from code review
ovflowd 412a7fb
Merge branch 'major/website-redesign' into chore/normalise-stories-re…
ovflowd 5fa8599
Merge branch 'major/website-redesign' into chore/normalise-stories-re…
ovflowd 88f12fb
chore: updated content from rebase (and fixed some styles)
ovflowd 8b1ad5d
chore: updated eslint rules and enforced them
ovflowd File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 hidden or 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,5 +1,8 @@ | ||
| # Default rules | ||
| * @nodejs/website | ||
|
|
||
| - @nodejs/website | ||
|
|
||
| # Node.js Release Blog Posts | ||
|
|
||
| /pages/en/blog/release @nodejs/releasers | ||
| /pages/en/blog/announcements @nodejs/releasers |
This file contains hidden or 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 hidden or 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 hidden or 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,9 +1,13 @@ | ||
| import Alert from './index'; | ||
| import type { Meta as MetaObj, StoryObj } from '@storybook/react'; | ||
|
|
||
| export default { component: Alert }; | ||
| type Story = StoryObj<typeof Alert>; | ||
| type Meta = MetaObj<typeof Alert>; | ||
|
|
||
| export const Default = { | ||
| export const Default: Story = { | ||
| args: { | ||
| children: 'This is an alert', | ||
| }, | ||
| }; | ||
|
|
||
| export default { component: Alert } as Meta; |
This file contains hidden or 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,8 +1,8 @@ | ||
| import React from 'react'; | ||
| import styles from './index.module.scss'; | ||
| import type { FC, PropsWithChildren } from 'react'; | ||
|
|
||
| const Alert = ({ children }: React.PropsWithChildren) => ( | ||
| <div className={styles.alert}>{children}</div> | ||
| const Alert: FC<PropsWithChildren> = props => ( | ||
| <div className={styles.alert}>{props.children}</div> | ||
| ); | ||
|
|
||
| export default Alert; |
This file contains hidden or 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,18 +1,22 @@ | ||
| import BlockQuote from './index'; | ||
| import type { Meta as MetaObj, StoryObj } from '@storybook/react'; | ||
|
|
||
| export default { component: BlockQuote }; | ||
| type Story = StoryObj<typeof BlockQuote>; | ||
| type Meta = MetaObj<typeof BlockQuote>; | ||
|
|
||
| export const Default = { | ||
| export const Default: Story = { | ||
| args: { | ||
| children: 'This is a block quote', | ||
| }, | ||
| }; | ||
|
|
||
| export const MultipleParagraph = { | ||
| export const MultipleParagraph: Story = { | ||
| args: { | ||
| children: [ | ||
| <p key={1}>This is a block quote 1</p>, | ||
| <p key={2}>This is a block quote 2</p>, | ||
| ], | ||
| }, | ||
| }; | ||
|
|
||
| export default { component: BlockQuote } as Meta; |
This file contains hidden or 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,8 +1,8 @@ | ||
| import type { PropsWithChildren } from 'react'; | ||
| import styles from './index.module.scss'; | ||
| import type { FC, PropsWithChildren } from 'react'; | ||
|
|
||
| const BlockQuote = ({ children }: PropsWithChildren) => ( | ||
| <div className={styles.blockQuote}>{children}</div> | ||
| const BlockQuote: FC<PropsWithChildren> = props => ( | ||
| <div className={styles.blockQuote}>{props.children}</div> | ||
| ); | ||
|
|
||
| export default BlockQuote; |
This file contains hidden or 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 hidden or 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 hidden or 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.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.