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

Version 3.0 #234

Open
wants to merge 20 commits into
base: main
Choose a base branch
from
Open

Version 3.0 #234

wants to merge 20 commits into from

Conversation

patinthehat
Copy link
Member

This pull request includes various updates to configuration files, build scripts, and dependencies. The most important changes are grouped into themes such as build system updates, dependency updates, and configuration updates.

This PR also significantly adds to the unit tests, increasing code coverage by ~40%.

Build System Updates:

  • Replaced Rollup with Vite for building the project and updated related scripts in package.json.
  • Updated the run-tests.yml workflow to use Bun instead of npm for installing dependencies and running tests.

Dependency Updates:

  • Updated dependencies in package.json to their latest versions and switched from Jest to Vitest for testing.

Configuration Updates:

  • Migrated ESLint config file from .eslintrc.js to eslint.config.js and updated the configuration format to the v9 format.
  • Updated .github/codecov.yml to adjust the coverage range and ignored files .

These changes aim to modernize the build and testing processes, update dependencies, and improve configuration management.

Copy link

what-the-diff bot commented Nov 12, 2024

PR Summary

  • Refactored Type Declarations in AlpineRay.ts
    The code has been updated to allow the use of both Window types and null, improving code flexibility and safety.

  • Enhanced Safety in AlpineRayMagicMethod.ts
    The code is now safer as it can handle undefined values better. This means that the program can now potentially avoid unexpected crashes.

  • Simplified 'ray' function in AlpineRay.ts
    The 'ray' function code has been condensed, making it easier to read and manage.

  • Introduced a New Global Declaration File 'globals.d.ts'
    Introduced a file called 'globals.d.ts' which includes type definitions related to the global Window object. This will make the code more consistent and easier to work with.

  • Improved Type Handling in 'utils.ts'
    Refactored code for specific types, such as Window or null, which makes it more clear about what type of data the functions in this file are working with. Added detailed comments to explain what each function does.

  • Streamlined Version Comparison Logic
    Improved the way version numbers are compared in the code by simplifying array handling, making the code better to understand and manage.

  • Enhanced Null-checks
    The system is now more robust in handling 'null' values. This means functions can handle missing information more gracefully and reduce the risk of crashes.

  • Removed Redundant Comments and To-dos
    The removal of unneeded comments and To-dos makes the code cleaner and easier to navigate.

  • Trimmed Unnecessary Imports
    Code is streamlined by removing ineffective imports, accelerating the speed of the application.

@patinthehat patinthehat added the WTD WhatTheDiff label Nov 12, 2024
Copy link

codecov bot commented Nov 12, 2024

Codecov Report

Attention: Patch coverage is 92.30769% with 3 lines in your changes missing coverage. Please review.

Project coverage is 74.86%. Comparing base (8fd9f20) to head (71a7ca9).
Report is 32 commits behind head on main.

Files with missing lines Patch % Lines
src/AlpineRayMagicMethod.ts 62.50% 3 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff             @@
##             main     #234       +/-   ##
===========================================
+ Coverage   36.82%   74.86%   +38.05%     
===========================================
  Files           5        6        +1     
  Lines         220      354      +134     
  Branches       80       95       +15     
===========================================
+ Hits           81      265      +184     
+ Misses        139       89       -50     
Files with missing lines Coverage Δ
src/AlpineRay.ts 100.00% <100.00%> (+73.08%) ⬆️
src/globals.d.ts 100.00% <100.00%> (ø)
src/lib/utils.ts 97.25% <100.00%> (+55.08%) ⬆️
src/AlpineRayMagicMethod.ts 49.38% <62.50%> (+19.08%) ⬆️

... and 2 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 4e5221b...71a7ca9. Read the comment docs.

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

Successfully merging this pull request may close these issues.

1 participant