Gathering detailed insights and metrics for better-cypress-axe
Gathering detailed insights and metrics for better-cypress-axe
Gathering detailed insights and metrics for better-cypress-axe
Gathering detailed insights and metrics for better-cypress-axe
npm install better-cypress-axe
Module System
Min. Node Version
Typescript Support
Node Version
NPM Version
1 Stars
26 Commits
1 Forks
3 Watching
14 Branches
2 Contributors
Updated on 18 Jul 2023
JavaScript (100%)
Cumulative downloads
Total Downloads
Last day
15.2%
76
Compared to previous day
Last week
-5.2%
380
Compared to previous week
Last month
130.9%
1,143
Compared to previous month
Last year
-65.5%
4,554
Compared to previous year
2
1
4
This package extends the existing and already awesome cypress-axe package. This package bundles the required axe-core dependencies, which is the reason why I felt it should be a separate package to cypress-axe.
Assuming you already have cypress installed and setup.
1npm install --dev better-cypress-axe 2 3# Alternatively if using yarn 4yarn add dev better-cypress-axe
NOTE: There is no need to add axe-core or cypress-axe as they're already bundled into this package to get around the issues mentioned above.
Then follow the steps from cypress-axe setup...
Import better-cypress-axe
by adding to cypress/support/index.js
1import "better-cypress-axe"
configureAxe - note this isn't required
You can define a custom cypress loggers and violation handing by passing in an object to the checkAlly
command.
This is useful for ensuring the logging follows a certain format, or that the final report doesn't fail a build.
You'll need to add a cypress task to log to the terminal console.
1const customViolationLogger = violation => cy.task("log", violation)
2const customViolationHandler = violation => cy.task("log", violation)
3
4cy.checkA11y(
5 context, // can use undefined
6 options, // can use undefined
7 {
8 logger: customViolationLogger,
9 asserter: customViolationHandler
10 }
11)
Add to cypress/typings.d.ts
1import "better-cypress-axe"
1# Use nvm or node version as per .nvmrc 2nvm use 3 4# Install Dependencies 5npm i 6 7# Build for deploy 8npm run build 9 10# Lint files 11npm run lint
Contributions and PR's welcome
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
Found 0/24 approved changesets -- score normalized to 0
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Reason
71 existing vulnerabilities detected
Details
Score
Last Scanned on 2024-11-18
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More