green-labs / res_tailwindcss

ReScript PPX which validates the tailwindcss class names
MIT License
28 stars 4 forks source link

add feature to find the closest missing class name #3

Closed mununki closed 2 years ago

mununki commented 2 years ago

Done https://github.com/green-labs/ppx_tailwindcss/commit/27bd8b4a0940a82bc3fa28fa3d71737338f4644a

Error message shows the corrected class name

>>>> Start compiling
rescript: [1/4] src/View.ast
FAILED: src/View.ast

  We've found a bug for you!
  /Users/woonki/Documents/projects/ppx_tailwindcss/test/src/View.res:1:14-30

  1 │ let header = %twc("containes")

  Class name not found: containes, do you mean container?

FAILED: cannot make progress due to previous errors.
>>>> Finish compiling(exit: 1)