
Research
/Security News
Intercom’s npm Package Compromised in Ongoing Mini Shai-Hulud Worm Attack
Compromised intercom-client@7.0.4 npm package is tied to the ongoing Mini Shai-Hulud worm attack targeting developer and CI/CD secrets.
babel-plugin-relay
Advanced tools
Relay requires a Babel plugin to convert GraphQL tags to runtime artifacts.
A very simplified example of what this plugin is doing:
// It converts this code
const fragment = graphql`
fragment User_fragment on User {
name
}
`;
// To require generated ASTs for fragments and queries
const fragment = require('__generated__/User_fragment.graphql');
babel-plugin-relay will discover the config if:
relay.config.json, relay.config.js file at the root of the
project (i.e. in the same folder as the package.json file).package.json file contains a "relay" key.babel-plugin-relayartifactDirectory A specific directory to output all artifacts to. When
enabling this the babel plugin needs artifactDirectory to be set as well.
[string]eagerEsModules This option enables emitting ES modules artifacts.
[boolean][default: false]codegenCommand The command to run to compile Relay files. [string]isDevVariableName Name of the global variable for dev mode (e.g. __DEV__).
[string]jsModuleFormat Formatting style for generated files. commonjs or haste.
Default is commonjs. [string]graphql-tag is a package used to parse GraphQL queries into the standard GraphQL AST. Unlike babel-plugin-relay, it does not perform any compilation or optimization of queries, but it is often used in environments where Relay is not required.
Apollo Client is a comprehensive state management library for JavaScript that enables you to manage both local and remote data with GraphQL. While it provides similar functionalities in terms of handling GraphQL queries, it is more focused on the Apollo ecosystem rather than Relay.
urql is a GraphQL client that is highly customizable and extensible. It provides a simpler alternative to Relay and Apollo Client, focusing on ease of use and flexibility, but does not offer the same level of query compilation and optimization as babel-plugin-relay.
FAQs
A Babel Plugin for use with Relay applications.
The npm package babel-plugin-relay receives a total of 579,455 weekly downloads. As such, babel-plugin-relay popularity was classified as popular.
We found that babel-plugin-relay demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 9 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
Compromised intercom-client@7.0.4 npm package is tied to the ongoing Mini Shai-Hulud worm attack targeting developer and CI/CD secrets.

Research
Socket detected a malicious supply chain attack on PyPI package lightning versions 2.6.2 and 2.6.3, which execute credential-stealing malware on import.

Research
A brand-squatted TanStack npm package used postinstall scripts to steal .env files and exfiltrate developer secrets to an attacker-controlled endpoint.