feat: enforce no-restricted-syntax for BigInt safety in core-ts#201
Merged
codeZe-us merged 1 commit intoBoxkit-Labs:mainfrom Mar 29, 2026
Merged
feat: enforce no-restricted-syntax for BigInt safety in core-ts#201codeZe-us merged 1 commit intoBoxkit-Labs:mainfrom
codeZe-us merged 1 commit intoBoxkit-Labs:mainfrom
Conversation
|
@A5cend-dev Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits. You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #194
#194 Enforce no-restricted-syntax for BigInt Safety
The Issue
needed a way to automatically stop developers from accidentally converting BigInt values to Number in the core-ts package. This is dangerous because JavaScript silently corrupts any number above 2^53-1 when you do that, which can break routing logic without any error.
What you did
You forked the repo and set it up locally on your machine. Since the core-ts package had no ESLint config, you created one from scratch — packages/core-ts/.eslintrc.js. Inside it, you configured a no-restricted-syntax rule that bans Number(), unary +, and parseFloat(), which are the main ways a developer could accidentally coerce a BigInt into a Number.
You also installed @typescript-eslint/parser so ESLint could read the TypeScript files in the package, since it couldn't parse them by default.
You then ran ESLint locally to verify it was working, and it caught a real violation in src/test/extract.test.ts at line 162 — proof that the rule is active and CI will now fail on any unsafe BigInt conversions.
Finally you committed only the .eslintrc.js file and pushed it to your fork, then opened a PR back to the original repo.