这是indexloc提供的服务,不要输入任何密码
Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: misund/passes-wcag
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v0.3.0
Choose a base ref
...
head repository: misund/passes-wcag
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: main
Choose a head ref
  • 10 commits
  • 11 files changed
  • 3 contributors

Commits on Jul 29, 2025

  1. v0.3.0 (#359)

    Updates all the dependencies.
    
    Switches from Travis to GitHub actions.
    Switches from Dependabot-preview to Dependabot.
    misund authored Jul 29, 2025
    Configuration menu
    Copy the full SHA
    9edf193 View commit details
    Browse the repository at this point in the history

Commits on Oct 11, 2025

  1. BREAKING: Convert to ESM-only, TypeScript, and upgrade build tools (#373

    )
    
    ## ⚠️ BREAKING CHANGE
    
    This PR converts the package to **ESM-only** and **TypeScript**. Projects using `require()` will need to migrate to ESM or use dynamic imports.
    
    After this PR CommonJS is no longer supported. See [ESM Module FAQ](https://gist.github.com/sindresorhus/a39789f98801d908bbc7ff3ecc99d99c).
    
    ## Summary
    This PR modernizes the build tooling to current standards:
    - **Convert from JavaScript to TypeScript**
    - **ESM** module format (breaking change)
    - **TypeScript 5.9.2**
    - **tsx** for test execution
    - **Node.js 20, 22, 24** support
    - **get-contrast-ratio@1.0.0-1** (ESM version)
    
    ## Changes
    
    ### TypeScript conversion
    - ✅ Convert src/index.js → src/index.ts with proper type annotations
    - ✅ Convert test/test.js → test/test.ts
    - ✅ Add TypeScript 5.9.2 with ES2022 target
    - ✅ Create tsconfig.json
    - ✅ Add return type annotations for all exported functions
    - ✅ Fix typo in package.json description: "if a to colors" → "if two colors"
    
    ### ESLint improvements
    - ✅ Update eslint.config.mjs to match other packages in cluster
    - ✅ Add TypeScript-specific linting rules
    - ✅ Add @typescript-eslint/eslint-plugin 7.18.0
    - ✅ Add @typescript-eslint/parser 7.18.0
    - ✅ Add eslint-config-prettier 10.1.8
    
    ### ESM conversion (⚠️ Breaking Change)
    - ✅ Add "type": "module" to package.json
    - ✅ Add exports field for proper ESM support
    - ✅ Update tsconfig.json to output ES2022 modules
    - ✅ Update test imports to use .js extension for ESM compatibility
    - ✅ Update get-contrast-ratio dependency from 0.2.1 to 1.0.0-1
    - ✅ Replace Babel with TypeScript compiler
    
    ### Build system improvements
    - ✅ Replace Babel with TypeScript compiler
    - ✅ Replace @babel/register with tsx for running tests
    - ✅ Create .mocharc.json to use tsx with --import flag
    - ✅ Add skipLibCheck to tsconfig for better compatibility
    - ✅ Add @types/node 22.10.5
    - ✅ Add @types/mocha 10.0.10
    
    ### CI/CD improvements
    - ✅ Update CI workflow to test on Node.js 20, 22, 24 (removing EOL Node 18)
    - ✅ Add explicit build verification step to workflow
    
    ### Testing improvements
    - ✅ Tests now run against TypeScript source directly (faster iteration)
    - ✅ Added test to verify built ESM output works correctly
    
    ## Migration Guide
    
    ### For consumers using CommonJS (require):
    ```javascript
    // ❌ No longer works
    const { passesWcagAa } = require('passes-wcag')
    
    // ✅ Option 1: Convert to ESM
    import { passesWcagAa } from 'passes-wcag'
    
    // ✅ Option 2: Use dynamic import
    const { passesWcagAa } = await import('passes-wcag')
    ```
    
    ### For consumers already using ESM:
    No changes needed - the package now properly exports ESM with full TypeScript types.
    
    ## Test plan
    - [x] Build succeeds (yarn build)
    - [x] Linting passes (yarn lint)
    - [x] All tests pass (yarn test)
    - [x] All 9 test cases passing (including new build output test)
    - [x] Built ESM output verified to work correctly
    
    🤖 Generated with [Claude Code](https://claude.com/claude-code)
    
    Co-authored-by: Claude <noreply@anthropic.com>
    misund and claude authored Oct 11, 2025
    Configuration menu
    Copy the full SHA
    6d999a6 View commit details
    Browse the repository at this point in the history
  2. build(deps-dev): bump eslint from 9.32.0 to 9.37.0 (#372)

    Bumps [eslint](https://github.com/eslint/eslint) from 9.32.0 to 9.37.0.
    - [Release notes](https://github.com/eslint/eslint/releases)
    - [Commits](eslint/eslint@v9.32.0...v9.37.0)
    
    ---
    updated-dependencies:
    - dependency-name: eslint
      dependency-version: 9.37.0
      dependency-type: direct:development
      update-type: version-update:semver-minor
    ...
    
    Signed-off-by: dependabot[bot] <support@github.com>
    Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
    dependabot[bot] authored Oct 11, 2025
    Configuration menu
    Copy the full SHA
    d56ed0d View commit details
    Browse the repository at this point in the history
  3. build(deps-dev): bump mocha from 11.7.1 to 11.7.4 (#371)

    Bumps [mocha](https://github.com/mochajs/mocha) from 11.7.1 to 11.7.4.
    - [Release notes](https://github.com/mochajs/mocha/releases)
    - [Changelog](https://github.com/mochajs/mocha/blob/main/CHANGELOG.md)
    - [Commits](mochajs/mocha@v11.7.1...v11.7.4)
    
    ---
    updated-dependencies:
    - dependency-name: mocha
      dependency-version: 11.7.4
      dependency-type: direct:development
      update-type: version-update:semver-patch
    ...
    
    Signed-off-by: dependabot[bot] <support@github.com>
    Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
    dependabot[bot] authored Oct 11, 2025
    Configuration menu
    Copy the full SHA
    2b40a35 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    463fa82 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    825f54b View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    4e355d6 View commit details
    Browse the repository at this point in the history
  7. build(deps-dev): bump @types/node from 22.10.5 to 24.7.1 (#374)

    Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 22.10.5 to 24.7.1.
    - [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
    - [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)
    
    ---
    updated-dependencies:
    - dependency-name: "@types/node"
      dependency-version: 24.7.1
      dependency-type: direct:development
      update-type: version-update:semver-major
    ...
    
    Signed-off-by: dependabot[bot] <support@github.com>
    Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
    dependabot[bot] authored Oct 11, 2025
    Configuration menu
    Copy the full SHA
    672aab9 View commit details
    Browse the repository at this point in the history

Commits on Oct 13, 2025

  1. Configuration menu
    Copy the full SHA
    bc27558 View commit details
    Browse the repository at this point in the history
  2. v1.0.0-0 (#379)

    misund authored Oct 13, 2025
    Configuration menu
    Copy the full SHA
    a1cdf3b View commit details
    Browse the repository at this point in the history
Loading