Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

refactor: Add storybook + initial story#118

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
bryphe-coder merged 7 commits intomainfrombryphe/refactor/add-storybook
Feb 4, 2022

Conversation

bryphe-coder
Copy link
Contributor

This hooks upstorybook, which the front-end team has enjoyed using in the v1 codebase - it makes it quick and easy to view and test components in isolation.

The<LoadingButton /> has a simple story added now, so if you runyarn storybook, you can preview it in various states:

2022-01-31 19 24 24

This will be helpful as we bring more front-end devs to help build v2 out.

@bryphe-coderbryphe-coder self-assigned thisFeb 1, 2022
@codecov
Copy link

codecovbot commentedFeb 1, 2022
edited
Loading

Codecov Report

Merging#118 (4de9feb) intomain (c65850b) willdecrease coverage by0.15%.
The diff coverage is0.00%.

Impacted file tree graph

@@            Coverage Diff             @@##             main     #118      +/-   ##==========================================- Coverage   67.72%   67.57%   -0.16%==========================================  Files         101      103       +2       Lines        5125     5132       +7       Branches       68       68              ==========================================- Hits         3471     3468       -3- Misses       1343     1353      +10  Partials      311      311
FlagCoverage Δ
unittest-go-macos-latest64.51% <ø> (+0.07%)⬆️
unittest-go-ubuntu-latest66.67% <ø> (-0.27%)⬇️
unittest-go-windows-latest?
unittest-js64.21% <0.00%> (-0.72%)⬇️
Impacted FilesCoverage Δ
site/.storybook/main.js0.00% <0.00%> (ø)
site/.storybook/preview.js0.00% <0.00%> (ø)
peer/channel.go84.75% <0.00%> (-2.44%)⬇️
provisionerd/provisionerd.go73.30% <0.00%> (-0.98%)⬇️
coderd/provisionerdaemons.go48.28% <0.00%> (ø)
peer/conn.go79.23% <0.00%> (+0.51%)⬆️
peerbroker/listen.go84.80% <0.00%> (+2.39%)⬆️

Continue to review full report at Codecov.

Legend -Click here to learn more
Δ = absolute <relative> (impact),ø = not affected,? = missing data
Powered byCodecov. Last updatec65850b...4de9feb. Read thecomment docs.

package.json Outdated
"format:write":"prettier --write '**/*.{css,html,js,json,jsx,md,ts,tsx,yaml,yml}' && sql-formatter -l postgresql ./database/query.sql -o ./database/query.sql",
"lint":"jest --selectProjects lint",
"lint:fix":"FIX=true yarn lint",
"storybook":"start-storybook -p 6006 -s ./site/static",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Should we put storybook and the package.json inside ofsite? Seems a bit weird to have at the root now that I look, especially becausenpm run X competes withMakefile.

bryphe-coder reacted with thumbs up emoji
Copy link
ContributorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Good question, there was a blocker I ran into when I tried that on initially porting code over - due to differences in TypeScript compile requirements fornextjs andjest - different requirements for thejsx option. However turns it out wasn't too hard to fix in#128

I've now rebased this PR on top of that change sostorybook lives completely insite now, too

bryphe-coder added a commit that referenced this pull requestFeb 1, 2022
#128)This refactors the front-end collateral to all live within `site` - so no `package.json` at the root.The reason we had this initially is that the jest test run and NextJS actually require having _two_ different `tsconfig`s - Next needs `jsx:"preserve"`, while jest needs `jsx:"react"` - we were using `tsconfig`s at different levels at the hierarchy to manage this.I changed this behavior to still use two different `tsconfig.json`s, which is mandatory - but just side-by-side in `site`.Once that's fixed, it was easy to move everything into `site`Follow up from:#118 (comment)
@bryphe-coderbryphe-coderforce-pushed thebryphe/refactor/add-storybook branch fromfc533b1 tof72ccb9CompareFebruary 1, 2022 22:48
@bryphe-coderbryphe-coder merged commit94f71fe intomainFeb 4, 2022
@bryphe-coderbryphe-coder deleted the bryphe/refactor/add-storybook branchFebruary 4, 2022 16:36
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@kylecarbskylecarbskylecarbs approved these changes

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

2 participants

@bryphe-coder@kylecarbs

[8]ページ先頭

©2009-2025 Movatter.jp