Skip to content
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

tailwind - throw error for invalid class name #1044

Closed
wants to merge 1 commit into from

Conversation

kyleleow
Copy link
Contributor

@kyleleow kyleleow commented Oct 13, 2021

What kind of PR is this?:

/kind feature

What this PR does / why we need it:

  • To make sure all tailwind class used are support

Which issue(s) does this PR fixes?:

Fixes #1002

Additional comments?:

Does not have an option to suppress exception based on environment

Developer Checklist:

  • Read your code changes at least once
  • Tested on iOS/Android device (e.g, No crashes, library supported etc.)
  • No console errors on web
  • Tested on Light mode and Dark mode*
  • Your UI implementation visually matched the rendered design*
  • Unit tests*
  • Added e2e tests*
  • Added translations*

@kyleleow kyleleow self-assigned this Oct 13, 2021
@netlify
Copy link

netlify bot commented Oct 13, 2021

❌ Deploy Preview for wallet-defichain failed.

🔨 Explore the source changes: c756fc9

🔍 Inspect the deploy log: https://app.netlify.com/sites/wallet-defichain/deploys/61666606b8049d0007fcd675

@defichain-bot defichain-bot added the kind/feature New feature request label Oct 13, 2021
@codeclimate
Copy link

codeclimate bot commented Oct 13, 2021

Code Climate has analyzed commit c756fc9 and detected 0 issues on this pull request.

View more on Code Climate.

@codecov
Copy link

codecov bot commented Oct 13, 2021

Codecov Report

Merging #1044 (c756fc9) into main (1fa7697) will increase coverage by 0.14%.
The diff coverage is 87.50%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #1044      +/-   ##
==========================================
+ Coverage   89.26%   89.41%   +0.14%     
==========================================
  Files         164      165       +1     
  Lines        2991     3003      +12     
  Branches      618      619       +1     
==========================================
+ Hits         2670     2685      +15     
+ Misses        319      316       -3     
  Partials        2        2              
Impacted Files Coverage Δ
mobile-app/app/tailwind.ts 91.66% <87.50%> (-8.34%) ⬇️
...pp/app/screens/WalletNavigator/WalletNavigator.tsx 100.00% <0.00%> (ø)
...lletNavigator/screens/CreateWallet/PinCreation.tsx 100.00% <0.00%> (ø)
...lletNavigator/screens/CreateWallet/PasscodeFaq.tsx 100.00% <0.00%> (ø)
mobile-app/app/components/BarCodeScanner.tsx 70.37% <0.00%> (+14.81%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1fa7697...c756fc9. Read the comment docs.

@netlify
Copy link

netlify bot commented Oct 13, 2021

✔️ Deploy Preview for mobile-wallet-preview ready!

🔨 Explore the source changes: c756fc9

🔍 Inspect the deploy log: https://app.netlify.com/sites/mobile-wallet-preview/deploys/6166660633dfda0008bccb9a

😎 Browse the preview: https://deploy-preview-1044--mobile-wallet-preview.netlify.app/

@defichain-bot
Copy link
Contributor

Build preview for DeFiChain Wallet is ready!

Built with commit 7265d4c

https://expo.io/@defichain/wallet?release-channel=pr-preview-1044

@cypress
Copy link

cypress bot commented Oct 13, 2021



Test summary

205 0 0 0


Run details

Project wallet
Status Passed
Commit 7265d4c ℹ️
Started Oct 13, 2021 4:55 AM
Ended Oct 13, 2021 5:01 AM
Duration 05:58 💡
OS Linux Ubuntu - 20.04
Browser Chrome 94

View run in Cypress Dashboard ➡️


This comment has been generated by cypress-bot as a result of this project's GitHub integration settings. You can manage this integration in this project's settings in the Cypress Dashboard

@@ -48,7 +50,16 @@ const created = create({ ...styles, ...fonts })
* @param {...Argument[]} args
*/
export function tailwind (...args: Argument[]): { [key: string]: string } {
validateTailwindClass(classNames(args).split(' '))
Copy link
Contributor

Choose a reason for hiding this comment

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

Not sure if this is compiled and will not run on production mode or just debug mode only.

If this code section run in production, it will be too "expensive"?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/feature New feature request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

tailwind - throw an error if CSS class is not existing
4 participants