Skip to content

fix(attributes-to-props): convert attribute to uncontrolled component prop#388

Merged
remarkablemark merged 2 commits intomasterfrom
fix/uncontrolled-components
Dec 13, 2021
Merged

fix(attributes-to-props): convert attribute to uncontrolled component prop#388
remarkablemark merged 2 commits intomasterfrom
fix/uncontrolled-components

Conversation

@remarkablemark
Copy link
Copy Markdown
Owner

Fixes #321

What is the motivation for this pull request?

fix(attributes-to-props): convert attribute to uncontrolled component prop

What is the current behavior?

HTML DOM attributes (checked and value) are rendered as controlled components:

  • checked -> checked
  • value -> value

What is the new behavior?

HTML DOM attributes (checked and value) are rendered as uncontrolled components:

  • checked -> defaultChecked
  • value -> defaultValue

Checklist:

@codecov-commenter
Copy link
Copy Markdown

Codecov Report

Merging #388 (6786046) into master (dcf4718) will not change coverage.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff            @@
##            master      #388   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            8         8           
  Lines          154       158    +4     
  Branches        54        55    +1     
=========================================
+ Hits           154       158    +4     
Impacted Files Coverage Δ
lib/attributes-to-props.js 100.00% <100.00%> (ø)

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 dcf4718...6786046. Read the comment docs.

@remarkablemark remarkablemark added the bug Something isn't working label Dec 13, 2021
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Dec 13, 2021

size-limit report 📦

Path Size Loading time (3g) Running time (snapdragon) Total time
dist/html-react-parser.min.js 9.33 KB (+0.34% 🔺) 187 ms (+0.34% 🔺) 75 ms (+13.56% 🔺) 262 ms

@remarkablemark remarkablemark merged commit 40d1369 into master Dec 13, 2021
@remarkablemark remarkablemark deleted the fix/uncontrolled-components branch December 13, 2021 23:12
@remarkablemark
Copy link
Copy Markdown
Owner Author

remarkablemark commented Dec 13, 2021

Released in #389 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Parsing <input> "checked" and "value"

2 participants