Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@linaria/utils

Package Overview
Dependencies
Maintainers
4
Versions
29
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@linaria/utils - npm Package Compare versions

Comparing version 4.0.0-beta.0 to 4.0.0-beta.1

7

esm/scopeHelpers.js

@@ -18,8 +18,8 @@ /* eslint-disable no-restricted-syntax */

export function reference(path, referencePath) {
if (!path.isReferencedIdentifier()) return;
export function reference(path, referencePath = path, force = false) {
if (!force && !path.isReferencedIdentifier()) return;
const binding = getBinding(path);
if (!binding) return;
if (binding.referencePaths.includes(referencePath ?? path)) {
if (binding.referencePaths.includes(referencePath)) {
return;

@@ -49,3 +49,2 @@ }

export function dereference(path) {
if (!path.isReferencedIdentifier()) return null;
const binding = getBinding(path);

@@ -52,0 +51,0 @@ if (!binding) return null;

@@ -38,8 +38,8 @@ "use strict";

function reference(path, referencePath) {
if (!path.isReferencedIdentifier()) return;
function reference(path, referencePath = path, force = false) {
if (!force && !path.isReferencedIdentifier()) return;
const binding = getBinding(path);
if (!binding) return;
if (binding.referencePaths.includes(referencePath !== null && referencePath !== void 0 ? referencePath : path)) {
if (binding.referencePaths.includes(referencePath)) {
return;

@@ -69,3 +69,2 @@ }

function dereference(path) {
if (!path.isReferencedIdentifier()) return null;
const binding = getBinding(path);

@@ -72,0 +71,0 @@ if (!binding) return null;

{
"name": "@linaria/utils",
"description": "Blazing fast zero-runtime CSS in JS library",
"version": "4.0.0-beta.0",
"version": "4.0.0-beta.1",
"bugs": "https://github.com/callstack/linaria/issues",
"dependencies": {
"@babel/core": "^7.18.2",
"@babel/core": "^7.18.9",
"@babel/plugin-proposal-export-namespace-from": ">=7",
"@babel/plugin-syntax-dynamic-import": ">=7",
"@babel/plugin-transform-modules-commonjs": "^7.18.2",
"@babel/traverse": ">=7",
"@babel/types": "^7.18.4",
"@linaria/logger": "^4.0.0-beta.0",
"@babel/traverse": "^7.18.9",
"@babel/types": "^7.18.9",
"@linaria/logger": "^4.0.0-beta.1",
"babel-merge": "^3.0.0"

@@ -15,0 +15,0 @@ },

@@ -28,3 +28,3 @@ <p align="center">

```sh
npm install @linaria/core @linaria/react @linaria/babel-preset @linaria/shaker
npm install @linaria/core @linaria/react @linaria/babel-preset
```

@@ -35,3 +35,3 @@

```sh
yarn add @linaria/core @linaria/react @linaria/babel-preset @linaria/shaker
yarn add @linaria/core @linaria/react @linaria/babel-preset
```
import type { Binding, NodePath } from '@babel/traverse';
import type { Identifier, JSXIdentifier } from '@babel/types';
export declare function reference(path: NodePath<Identifier | JSXIdentifier>, referencePath?: NodePath): void;
export declare function reference(path: NodePath<Identifier | JSXIdentifier>, referencePath?: NodePath, force?: boolean): void;
export declare function dereference(path: NodePath<Identifier | JSXIdentifier>): Binding | null;

@@ -5,0 +5,0 @@ export declare function referenceAll(path: NodePath): void;

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc