Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
@remix-run/eslint-config
Advanced tools
@remix-run/eslint-config
This package includes a shareable ESLint config for Remix projects.
If you create your app with create-remix
no additional configuration is necessary.
First, install this package along with ESLint in your project. This package requires at least version 8.1 of ESLint
npm install -D eslint @remix-run/eslint-config
Then create a file named .eslintrc.js
in the root of your project:
module.exports = {
extends: "@remix-run/eslint-config",
};
This packages also ships with optional configuration options for projects that use Jest with Testing Library. To enable these rules, add the following to your .eslintrc
:
module.exports = {
extends: [
"@remix-run/eslint-config",
"@remix-run/eslint-config/jest-testing-library",
],
};
Please note that because this ruleset is optional, we do not include the core libraries as peer dependencies for this package. If you use these rules, be sure that you have the following dependencies installed in your project:
{
"dependencies": {
"@testing-library/jest-dom": ">=5.16.0",
"@testing-library/react": ">=12.0.0",
"jest": ">=28.0.0"
}
}
v2.9.2
Date: 2024-05-10
In 2.9.2 we've enhanced the type-safety when opting into the future.unstable_singleFetch
feature. Previously, we added the response
stub to LoaderFunctionArgs
and used type overrides for inference on useLoaderData
, etc., but we found that it wasn't quite enough.
With this release we're introducing new functions to assist the type-inference when using single fetch - defineLoader
/defineAction
and their client-side counterparts defineClientLoader
and nd defineClientAction
. These are identity functions; they don't modify your loader or action at runtime. Rather, they exist solely for type-safety by providing types for args and by ensuring valid return types.
export const loader = defineLoader(({ request }) => {
// ^? Request
return { a: 1, b: () => 2 };
// ^ type error: `b` is not serializable
});
Note that defineLoader
and defineAction
are not technically necessary for defining loaders and actions if you aren't concerned with type-safety:
// this totally works! and typechecking is happy too!
export const loader = () => {
return { a: 1 };
};
This means that you can opt-in to defineLoader
incrementally, one loader at a time.
Please see the Single Fetch docs for more information.
@remix-run/dev
- Vite: Fix dest already exists
error when running remix vite:build
(#9305)@remix-run/dev
- Vite: Fix issue resolving critical CSS during development when route files are located outside of the app directory (#9194)@remix-run/dev
- Vite: Remove @remix-run/node
from Vite plugin's optimizeDeps.include
list since it was unnecessary and resulted in Vite warnings when not depending on this package (#9287)@remix-run/dev
- Vite: Clean up redundant ?client-route=1
imports in development (#9395)@remix-run/dev
- Vite: Ensure Babel config files are not referenced when applying the react-refresh
Babel transform within the Remix Vite plugin (#9241)@remix-run/react
- Type-safety for single-fetch: defineLoader
, defineClientLoader
, defineAction
, defineClientAction
(#9372)@remix-run/react
- Single Fetch: Add undefined
to useActionData
type override (#9322)@remix-run/react
- Single Fetch: Allow a nonce
to be set on single fetch stream transfer inline scripts via <RemixServer>
(#9364)@remix-run/server-runtime
- Single Fetch: Don't log thrown response stubs via handleError
(#9369)@remix-run/server-runtime
- Single Fetch: Automatically wrap resource route naked object returns in json()
for back-compat in v2 (and log deprecation warning) (#9349)@remix-run/server-runtime
- Single Fetch: Pass response
stub to resource route handlers (#9349)@remix-run/cloudflare
@remix-run/cloudflare-pages
@remix-run/cloudflare-workers
@remix-run/css-bundle
@remix-run/deno
@remix-run/dev
@remix-run/eslint-config
@remix-run/express
@remix-run/node
@remix-run/react
@remix-run/serve
@remix-run/server-runtime
@remix-run/testing
Full Changelog: v2.9.1...v2.9.2
FAQs
ESLint configuration for Remix projects
The npm package @remix-run/eslint-config receives a total of 111,068 weekly downloads. As such, @remix-run/eslint-config popularity was classified as popular.
We found that @remix-run/eslint-config demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.