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

Remove button role for links with an href #390

Merged

Conversation

Chapabu
Copy link
Contributor

@Chapabu Chapabu commented Oct 29, 2021

Closes #388

I went to write some tests for this and noticed the TODO regarding moving to @testing-library/react, so I took the liberty of adding it and writing the tests using @testing-library/react as there weren't any for the component I edited.

I also tested it manually by adding a hrefBuilder prop in the demo, however this is not committed as I didn't want to alter the demo unnecessarily.

Lastly, I had to use promises as it was complaining about needed regenerator-runtime. In the interest of getting it done, I just returned the promise from the test rather than doing anything fancy.

@mattc-cogapp
Copy link

Lastly, I had to use promises as it was complaining about needed regenerator-runtime.

Sorry, I meant using promises rather than async/await.

@MonsieurV MonsieurV merged commit d554699 into AdeleD:master Oct 29, 2021
@MonsieurV
Copy link
Collaborator

Perfect, thanks @mattc-cogapp!

I've done the setup to use async/await in tests.

Can you validate the build is working well for you? (I've changed Webpack version)

You can install the latest changes from master with:

npm install --save github:AdeleD/react-paginate#master

@Chapabu
Copy link
Contributor Author

Chapabu commented Nov 23, 2021

@MonsieurV Apologies for the delay with this - can confirm everything works fine :)

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

Successfully merging this pull request may close these issues.

Links with href attributes via hrefBuilder should not have a button role
3 participants