profile
viewpoint
Sunil Pai threepointone Bangalore, India

emotion-js/emotion 11630

👩‍🎤 CSS-in-JS library designed for high performance style composition

threepointone/css-suspense 310

css loading for react

TheLarkInn/unity-component-specification 211

This is a WIP draft of the Unity (Single File Web Component) Specification

threepointone/bs-nice 188

css-in-reason

threepointone/babel-macros 12

macros for babel. I think.

threepointone/asyncstorage-mock 9

a mock for react-native's asyncstorage api. useful for testing.

threepointone/css-in-js-workshop 6

css, in your js, in your head, in your heart

paramaggarwal/Rubber 2

iOS apps in Javascript like React Native.

threepointone/bus 2

global event bus

threepointone/async-act-test-21-11 1

Created with CodeSandbox

PullRequestReviewEvent

Pull request review commentreactjs/react-codemod

update-react-imports: Destructure named exports

 module.exports = function(file, api, options) {         path.value.source.value === 'React' ||         path.value.source.value === 'react'       );-    })-    .filter(path => {-      return (-        path.value.specifiers.length > 0 &&-        path.value.importKind === 'value' &&-        path.value.specifiers.some(-          specifier => specifier.local.name === 'React',-        )-      );     }); -  if (reactImportPath.size() > 1) {+  // get all namespace/default React imports+  const reactPaths = reactImportPaths.filter(path => {+    return (+      path.value.specifiers.length > 0 &&+      path.value.importKind === 'value' &&+      path.value.specifiers.some(specifier => specifier.local.name === 'React')+    );+  });++  if (reactPaths.size() > 1) {     throw Error(       'There should only be one React import. Please remove the duplicate import and try again.',     );   } -  if (reactImportPath.size() === 0) {+  if (reactPaths.size() === 0) {     return null;   } -  const keepReactImport =+  const reactPath = reactPaths.paths()[0];++  const isDefaultImport = reactPath.value.specifiers.some(+    specifier =>+      specifier.type === 'ImportDefaultSpecifier' &&+      specifier.local.name === 'React',+  );++  // Check to see if we should keep the React import+  const reactImportInUse =

been preferring 'predicate' style variable names for booleans lately.

  const isReactImportUsed =
lunaruan

comment created time in 6 days

Pull request review commentreactjs/react-codemod

update-react-imports: Destructure named exports

 module.exports = function(file, api, options) {       })       .size() > 0; -  const reactPath = reactImportPath.paths()[0];-  const specifiers = reactPath.value.specifiers;+  // local: imported+  const reactIdentifiers = {};+  const reactTypeIdentifiers = {};+  let canDestructureReactVariable;+  if (reactImportInUse && isDefaultImport) {+    // Checks to see if the react variable is used itself (rather than used to access its properties)+    canDestructureReactVariable =+      root+        .find(j.Identifier, {+          name: 'React',+        })+        .filter(path => {+          return path.parent.parent.value.type !== 'ImportDeclaration';+        })+        .filter(+          path =>+            !(+              path.parent.value.type === 'MemberExpression' &&+              path.parent.value.object.name === 'React'+            ) &&+            !(+              path.parent.value.type === 'QualifiedTypeIdentifier' &&+              path.parent.value.qualification.name === 'React'+            ) &&+            !(+              path.parent.value.type === 'JSXMemberExpression' &&+              path.parent.value.object.name === 'React'+            ),+        )+        .size() === 0; -  for (let i = 0; i < specifiers.length; i++) {-    const specifier = specifiers[i];-    if (specifier.local.name === 'React') {-      if (specifier.type === 'ImportNamespaceSpecifier' && !keepReactImport) {-        j(reactPath).remove();+    if (canDestructureReactVariable) {+      // If a variable that we are trying to import has already been declared,+      // do not try to destructure imports+      root+        .find(j.QualifiedTypeIdentifier, {+          qualification: {+            type: 'Identifier',+            name: 'React',+          },+        })+        .forEach(path => {+          const id = path.value.id.name;+          // This is a typeof import so it isn't actually a type+          if (path.parent.parent.value.type === 'TypeofTypeAnnotation') {

Move the comment inside the condition

          if (path.parent.parent.value.type === 'TypeofTypeAnnotation') {
            // This is a typeof import so it isn't actually a type
lunaruan

comment created time in 6 days

Pull request review commentreactjs/react-codemod

update-react-imports: Destructure named exports

 module.exports = function(file, api, options) {       })       .size() > 0; -  const reactPath = reactImportPath.paths()[0];-  const specifiers = reactPath.value.specifiers;+  // local: imported+  const reactIdentifiers = {};+  const reactTypeIdentifiers = {};+  let canDestructureReactVariable;+  if (reactImportInUse && isDefaultImport) {+    // Checks to see if the react variable is used itself (rather than used to access its properties)+    canDestructureReactVariable =+      root+        .find(j.Identifier, {+          name: 'React',+        })+        .filter(path => {+          return path.parent.parent.value.type !== 'ImportDeclaration';+        })+        .filter(+          path =>+            !(+              path.parent.value.type === 'MemberExpression' &&+              path.parent.value.object.name === 'React'+            ) &&+            !(+              path.parent.value.type === 'QualifiedTypeIdentifier' &&+              path.parent.value.qualification.name === 'React'+            ) &&+            !(+              path.parent.value.type === 'JSXMemberExpression' &&+              path.parent.value.object.name === 'React'+            ),+        )+        .size() === 0; -  for (let i = 0; i < specifiers.length; i++) {-    const specifier = specifiers[i];-    if (specifier.local.name === 'React') {-      if (specifier.type === 'ImportNamespaceSpecifier' && !keepReactImport) {-        j(reactPath).remove();+    if (canDestructureReactVariable) {+      // If a variable that we are trying to import has already been declared,+      // do not try to destructure imports

What happens in the future when only the destructured imports work? Feels like we should at least drop a warning here that they need to fix it by hand or whatever. Or we should re-alias the import and use a new named version instead.

lunaruan

comment created time in 6 days

Pull request review commentreactjs/react-codemod

update-react-imports: Destructure named exports

 module.exports = function(file, api, options) {   const printOptions = options.printOptions || {};   const root = j(file.source); -  const reactImportPath = root+  const variableAlreadyDeclared = variable => {+    const foo =+      root+        .find(j.Identifier, {+          name: variable,+        })+        .filter(+          path =>+            path.parent.value.type !== 'MemberExpression' &&+            path.parent.value.type !== 'QualifiedTypeIdentifier' &&+            path.parent.value.type !== 'JSXMemberExpression',+        )+        .size() > 0;+    return foo;

trying to avoid 'foo' as a variable name

    const variableReferences =
      root
        .find(j.Identifier, {
          name: variable,
        })
        .filter(
          path =>
            path.parent.value.type !== 'MemberExpression' &&
            path.parent.value.type !== 'QualifiedTypeIdentifier' &&
            path.parent.value.type !== 'JSXMemberExpression',
        );
    return variableReferences.size() > 0;
lunaruan

comment created time in 6 days

Pull request review commentreactjs/react-codemod

update-react-imports: Destructure named exports

 module.exports = function(file, api, options) {       })       .size() > 0; -  const reactPath = reactImportPath.paths()[0];-  const specifiers = reactPath.value.specifiers;+  // local: imported+  const reactIdentifiers = {};+  const reactTypeIdentifiers = {};+  let canDestructureReactVariable;+  if (reactImportInUse && isDefaultImport) {+    // Checks to see if the react variable is used itself (rather than used to access its properties)+    canDestructureReactVariable =+      root+        .find(j.Identifier, {+          name: 'React',+        })+        .filter(path => {+          return path.parent.parent.value.type !== 'ImportDeclaration';+        })+        .filter(+          path =>+            !(+              path.parent.value.type === 'MemberExpression' &&+              path.parent.value.object.name === 'React'+            ) &&+            !(+              path.parent.value.type === 'QualifiedTypeIdentifier' &&+              path.parent.value.qualification.name === 'React'+            ) &&+            !(+              path.parent.value.type === 'JSXMemberExpression' &&+              path.parent.value.object.name === 'React'+            ),+        )+        .size() === 0; -  for (let i = 0; i < specifiers.length; i++) {-    const specifier = specifiers[i];-    if (specifier.local.name === 'React') {-      if (specifier.type === 'ImportNamespaceSpecifier' && !keepReactImport) {-        j(reactPath).remove();+    if (canDestructureReactVariable) {+      // If a variable that we are trying to import has already been declared,+      // do not try to destructure imports+      root+        .find(j.QualifiedTypeIdentifier, {+          qualification: {+            type: 'Identifier',+            name: 'React',+          },+        })+        .forEach(path => {+          const id = path.value.id.name;+          // This is a typeof import so it isn't actually a type+          if (path.parent.parent.value.type === 'TypeofTypeAnnotation') {+            reactIdentifiers[id] = id;++            if (reactTypeIdentifiers[id]) {+              canDestructureReactVariable = false;+            }+          } else {+            reactTypeIdentifiers[id] = id;++            if (reactIdentifiers[id]) {+              canDestructureReactVariable = false;+            }+          }++          if (variableAlreadyDeclared(id)) {+            canDestructureReactVariable = false;+          }+        });++      root

please add a comment here to what this block of code does?

lunaruan

comment created time in 6 days

Pull request review commentreactjs/react-codemod

update-react-imports: Destructure named exports

 module.exports = function(file, api, options) {       })       .size() > 0; -  const reactPath = reactImportPath.paths()[0];-  const specifiers = reactPath.value.specifiers;+  // local: imported+  const reactIdentifiers = {};+  const reactTypeIdentifiers = {};+  let canDestructureReactVariable;+  if (reactImportInUse && isDefaultImport) {+    // Checks to see if the react variable is used itself (rather than used to access its properties)+    canDestructureReactVariable =+      root+        .find(j.Identifier, {+          name: 'React',+        })+        .filter(path => {+          return path.parent.parent.value.type !== 'ImportDeclaration';+        })+        .filter(+          path =>+            !(+              path.parent.value.type === 'MemberExpression' &&+              path.parent.value.object.name === 'React'+            ) &&+            !(+              path.parent.value.type === 'QualifiedTypeIdentifier' &&+              path.parent.value.qualification.name === 'React'+            ) &&+            !(+              path.parent.value.type === 'JSXMemberExpression' &&+              path.parent.value.object.name === 'React'+            ),+        )+        .size() === 0; -  for (let i = 0; i < specifiers.length; i++) {-    const specifier = specifiers[i];-    if (specifier.local.name === 'React') {-      if (specifier.type === 'ImportNamespaceSpecifier' && !keepReactImport) {-        j(reactPath).remove();+    if (canDestructureReactVariable) {+      // If a variable that we are trying to import has already been declared,+      // do not try to destructure imports+      root+        .find(j.QualifiedTypeIdentifier, {+          qualification: {+            type: 'Identifier',+            name: 'React',+          },+        })+        .forEach(path => {+          const id = path.value.id.name;+          // This is a typeof import so it isn't actually a type+          if (path.parent.parent.value.type === 'TypeofTypeAnnotation') {+            reactIdentifiers[id] = id;++            if (reactTypeIdentifiers[id]) {+              canDestructureReactVariable = false;+            }+          } else {+            reactTypeIdentifiers[id] = id;++            if (reactIdentifiers[id]) {+              canDestructureReactVariable = false;+            }+          }++          if (variableAlreadyDeclared(id)) {+            canDestructureReactVariable = false;+          }+        });++      root+        .find(j.MemberExpression, {+          object: {+            type: 'Identifier',+            name: 'React',+          },+        })+        .forEach(path => {+          const property = path.value.property.name;+          reactIdentifiers[property] = property;++          if (+            variableAlreadyDeclared(property) ||+            reactTypeIdentifiers[property]+          ) {+            canDestructureReactVariable = false;+          }+        });++      root

comment here too, please

lunaruan

comment created time in 6 days

Pull request review commentreactjs/react-codemod

update-react-imports: Destructure named exports

+import * as React from "react";++React.createElement('div', {});

I thought the goal was to move away from createElement completely at some point, but I suppose that's separate form this 👍

lunaruan

comment created time in 6 days

PullRequestReviewEvent
PullRequestReviewEvent

Pull request review commentreactjs/react-codemod

update-react-imports: Destructure named exports

 module.exports = function(file, api, options) {   const printOptions = options.printOptions || {};   const root = j(file.source); -  const reactImportPath = root+  const variableAlreadyDeclared = variable => {

I got confused when this was used as a function later, it kinda gets lost in all the other declarations. Maybe use a function declaration here?

  function variableDeclared(variable) {
lunaruan

comment created time in 6 days

Pull request review commentreactjs/react-codemod

update-react-imports: Destructure named exports

 module.exports = function(file, api, options) {       })       .size() > 0; -  const reactPath = reactImportPath.paths()[0];-  const specifiers = reactPath.value.specifiers;+  // local: imported+  const reactIdentifiers = {};+  const reactTypeIdentifiers = {};+  let canDestructureReactVariable;+  if (reactImportInUse && isDefaultImport) {+    // Checks to see if the react variable is used itself (rather than used to access its properties)+    canDestructureReactVariable =+      root+        .find(j.Identifier, {+          name: 'React',+        })+        .filter(path => {+          return path.parent.parent.value.type !== 'ImportDeclaration';+        })+        .filter(+          path =>+            !(+              path.parent.value.type === 'MemberExpression' &&+              path.parent.value.object.name === 'React'+            ) &&+            !(+              path.parent.value.type === 'QualifiedTypeIdentifier' &&+              path.parent.value.qualification.name === 'React'+            ) &&+            !(+              path.parent.value.type === 'JSXMemberExpression' &&+              path.parent.value.object.name === 'React'+            ),+        )+        .size() === 0; -  for (let i = 0; i < specifiers.length; i++) {-    const specifier = specifiers[i];-    if (specifier.local.name === 'React') {-      if (specifier.type === 'ImportNamespaceSpecifier' && !keepReactImport) {-        j(reactPath).remove();+    if (canDestructureReactVariable) {+      // If a variable that we are trying to import has already been declared,+      // do not try to destructure imports+      root+        .find(j.QualifiedTypeIdentifier, {+          qualification: {+            type: 'Identifier',+            name: 'React',+          },+        })+        .forEach(path => {+          const id = path.value.id.name;+          // This is a typeof import so it isn't actually a type+          if (path.parent.parent.value.type === 'TypeofTypeAnnotation') {+            reactIdentifiers[id] = id;++            if (reactTypeIdentifiers[id]) {+              canDestructureReactVariable = false;+            }+          } else {+            reactTypeIdentifiers[id] = id;++            if (reactIdentifiers[id]) {+              canDestructureReactVariable = false;+            }+          }++          if (variableAlreadyDeclared(id)) {+            canDestructureReactVariable = false;+          }+        });++      root+        .find(j.MemberExpression, {+          object: {+            type: 'Identifier',+            name: 'React',+          },+        })+        .forEach(path => {+          const property = path.value.property.name;+          reactIdentifiers[property] = property;++          if (+            variableAlreadyDeclared(property) ||+            reactTypeIdentifiers[property]+          ) {+            canDestructureReactVariable = false;+          }+        });++      root+        .find(j.JSXMemberExpression, {+          object: {+            type: 'JSXIdentifier',+            name: 'React',+          },+        })+        .forEach(path => {+          const property = path.value.property.name;+          reactIdentifiers[property] = property;++          if (+            variableAlreadyDeclared(property) ||+            reactTypeIdentifiers[property]+          ) {+            canDestructureReactVariable = false;+          }+        });+    }+  }++  if (canDestructureReactVariable) {+    // replace react identifiers+    root+      .find(j.QualifiedTypeIdentifier, {+        qualification: {+          type: 'Identifier',+          name: 'React',+        },+      })+      .forEach(path => {+        const id = path.value.id.name;++        j(path).replaceWith(j.identifier(id));+      });++    root+      .find(j.MemberExpression, {+        object: {+          type: 'Identifier',+          name: 'React',+        },+      })+      .forEach(path => {+        const property = path.value.property.name;++        j(path).replaceWith(j.identifier(property));+      });+    +    root+      .find(j.JSXMemberExpression, {+        object: {+          type: 'JSXIdentifier',+          name: 'React',+        },+      })+      .forEach(path => {+        const property = path.value.property.name;++        j(path).replaceWith(j.jsxIdentifier(property));+      });++    // Add exisiting React imports to map+    reactImportPaths.forEach(path => {+      const specifiers = path.value.specifiers;+      for (let i = 0; i < specifiers.length; i++) {+        const specifier = specifiers[i];+        // get all type and regular imports that are imported+        // from React+        if (specifier.type === 'ImportSpecifier') {+          if (+            path.value.importKind === 'type' ||+            specifier.importKind === 'type'+          ) {+            reactTypeIdentifiers[specifier.local.name] =+              specifier.imported.name;+          } else {+            reactIdentifiers[specifier.local.name] = specifier.imported.name;+          }+        }+      }+    });++    const regularImports = [];+    Object.keys(reactIdentifiers).forEach(local => {+      const imported = reactIdentifiers[local];+      regularImports.push(+        j.importSpecifier(j.identifier(imported), j.identifier(local)),+      );+    });++    const typeImports = [];+    Object.keys(reactTypeIdentifiers).forEach(local => {+      const imported = reactTypeIdentifiers[local];+      typeImports.push(+        j.importSpecifier(j.identifier(imported), j.identifier(local)),+      );+    });++    if (regularImports.length > 0) {+      j(reactPath).insertAfter(+        j.importDeclaration(regularImports, j.literal('react')),+      );+    }+    if (typeImports.length > 0) {+      j(reactPath).insertAfter(+        j.importDeclaration(typeImports, j.literal('react'), 'type'),+      );+    }++    // remove all old react imports+    reactImportPaths.forEach(path => {+      // This is for import type React from 'react' which shouldn't+      // be removed+      if (+        path.value.specifiers.some(+          specifier =>+            specifier.type === 'ImportDefaultSpecifier' &&+            specifier.local.name === 'React' &&+            (specifier.importKind === 'type' ||+              path.value.importKind === 'type'),+        )+      ) {+        j(path).insertAfter(+          j.importDeclaration(+            [j.importDefaultSpecifier(j.identifier('React'))],+            j.literal('react'),+            'type',+          ),+        );+      }+      j(path).remove();+    });+  } else {+    // Remove the import because it's not being used+    // If we should keep the React import, just convert+    // default imports to named imports+    let importRemoved = false;
    let isImportRemoved = false;
lunaruan

comment created time in 6 days

Pull request review commentreactjs/react-codemod

update-react-imports: Destructure named exports

+import * as React from "react";++React.createElement('div', {});++createElement('someFunction');

This hasn't been manually destructed so would likely fail in runtime, (or rather, the assumption will be that it's defined globally) Could you explain this testcase?

lunaruan

comment created time in 13 days

Pull request review commentreactjs/react-codemod

update-react-imports: Destructure named exports

+ 

Was this meant to be empty output?

lunaruan

comment created time in 13 days

Pull request review commentreactjs/react-codemod

update-react-imports: Destructure named exports

+import * as React from "react";++React.createElement('div', {});

feels like the destructuring would still be useful here. Is the decision to bail completely?

lunaruan

comment created time in 13 days

Pull request review commentreactjs/react-codemod

update-react-imports: Destructure named exports

-import * as React from "react";+import { createElement } from "react"; -React.createElement('div', {});+createElement('div', {});

dope, love it.

lunaruan

comment created time in 13 days

Pull request review commentreactjs/react-codemod

update-react-imports: Destructure named exports

+import { Fragment, useState } from "react";++<React.Fragment />

Shouldn't this become <Fragment/>?

lunaruan

comment created time in 13 days

Pull request review commentreactjs/react-codemod

update-react-imports: Destructure named exports

 npx react-codemod sort-comp <path>  #### `update-react-imports` -[As of Babel 7.9.0](https://babeljs.io/blog/2020/03/16/7.9.0#a-new-jsx-transform-11154-https-githubcom-babel-babel-pull-11154), when using `runtime: automatic` in `@babel/preset-react` or `@babel/plugin-transform-react-jsx`, you will not need to explicitly import React for compiling jsx. This codemod removes the redundant import statements. It also converts  (`import React from 'react'`) to named imports (`import * as React from 'react`).+[As of Babel 7.9.0](https://babeljs.io/blog/2020/03/16/7.9.0#a-new-jsx-transform-11154-https-githubcom-babel-babel-pull-11154), when using `runtime: automatic` in `@babel/preset-react` or `@babel/plugin-transform-react-jsx`, you will not need to explicitly import React for compiling jsx. This codemod removes the redundant import statements. It also converts  (`import React from 'react'`) to destructured named imports (`import { useState } as React from 'react`).

This edit seems a bit oddly structured, might want to edit in (it's fine if it's in a future PR, not critical). Might not even need it, tbh.

lunaruan

comment created time in 13 days

Pull request review commentreactjs/react-codemod

update-react-imports: Destructure named exports

+import * as React from 'react';

is the .output.js for this file meant to be empty? (I can't leave this comment on the output file because it's empty)

lunaruan

comment created time in 13 days

PullRequestReviewEvent
PullRequestReviewEvent

issue commentfacebook/create-react-app

Path in react-scripts seems to be somehow broken after `npm audit fix --force`

I think the public folder has to be besides the src folder instead of inside it; i.e., instead of

frontend 
  src 
    public 

it should be

frontend 
  src 
  public 

could you try moving the public folder up by one level and trying?

Lukortech

comment created time in 13 days

fork threepointone/tree-online

An online tree-like utility for generating ASCII folder structure diagrams. Written in TypeScript and React.

https://tree.nathanfriend.io

fork in 19 days

startedreactjs/react-gradual-upgrade-demo

started time in 19 days

push eventreactjs/react-gradual-upgrade-demo

Sunil Pai

commit sha 5090862a2f90f89d364191129ab78ad3af1d78f8

just a small typo in createLegacyRoot.js 🐢

view details

push time in 19 days

created repositorythreepointone/spaced-out

created time in a month

push eventreactjs/react-codemod

dependabot[bot]

commit sha 84adc1ef0a6c5b335ec17038e077c35e221a70c0

Bump lodash from 4.17.15 to 4.17.19 (#267) Bumps [lodash](https://github.com/lodash/lodash) from 4.17.15 to 4.17.19. - [Release notes](https://github.com/lodash/lodash/releases) - [Commits](https://github.com/lodash/lodash/compare/4.17.15...4.17.19) Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

view details

push time in 2 months

PR merged reactjs/react-codemod

Bump lodash from 4.17.15 to 4.17.19 dependencies

Bumps lodash from 4.17.15 to 4.17.19. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/lodash/lodash/releases">lodash's releases</a>.</em></p> <blockquote> <h2>4.17.16</h2> </blockquote> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/lodash/lodash/commit/d7fbc52ee0466a6d248f047b5d5c3e6d1e099056"><code>d7fbc52</code></a> Bump to v4.17.19</li> <li><a href="https://github.com/lodash/lodash/commit/2e1c0f22f425e9c013815b2cd7c2ebd51f49a8d6"><code>2e1c0f2</code></a> Add npm-package</li> <li><a href="https://github.com/lodash/lodash/commit/1b6c282299f4e0271f932b466c67f0f822aa308e"><code>1b6c282</code></a> Bump to v4.17.18</li> <li><a href="https://github.com/lodash/lodash/commit/a370ac81408de2da77a82b3c4b61a01a3b9c2fac"><code>a370ac8</code></a> Bump to v4.17.17</li> <li><a href="https://github.com/lodash/lodash/commit/1144918f3578a84fcc4986da9b806e63a6175cbb"><code>1144918</code></a> Rebuild lodash and docs</li> <li><a href="https://github.com/lodash/lodash/commit/3a3b0fd339c2109563f7e8167dc95265ed82ef3e"><code>3a3b0fd</code></a> Bump to v4.17.16</li> <li><a href="https://github.com/lodash/lodash/commit/c84fe82760fb2d3e03a63379b297a1cc1a2fce12"><code>c84fe82</code></a> fix(zipObjectDeep): prototype pollution (<a href="https://github-redirect.dependabot.com/lodash/lodash/issues/4759">#4759</a>)</li> <li><a href="https://github.com/lodash/lodash/commit/e7b28ea6cb17b4ca021e7c9d66218c8c89782f32"><code>e7b28ea</code></a> Sanitize sourceURL so it cannot affect evaled code (<a href="https://github-redirect.dependabot.com/lodash/lodash/issues/4518">#4518</a>)</li> <li><a href="https://github.com/lodash/lodash/commit/0cec225778d4ac26c2bac95031ecc92a94f08bbb"><code>0cec225</code></a> Fix lodash.isEqual for circular references (<a href="https://github-redirect.dependabot.com/lodash/lodash/issues/4320">#4320</a>) (<a href="https://github-redirect.dependabot.com/lodash/lodash/issues/4515">#4515</a>)</li> <li><a href="https://github.com/lodash/lodash/commit/94c3a8133cb4fcdb50db72b4fd14dd884b195cd5"><code>94c3a81</code></a> Document matches* shorthands for over* methods (<a href="https://github-redirect.dependabot.com/lodash/lodash/issues/4510">#4510</a>) (<a href="https://github-redirect.dependabot.com/lodash/lodash/issues/4514">#4514</a>)</li> <li>Additional commits viewable in <a href="https://github.com/lodash/lodash/compare/4.17.15...4.17.19">compare view</a></li> </ul> </details> <details> <summary>Maintainer changes</summary> <p>This version was pushed to npm by <a href="https://www.npmjs.com/~mathias">mathias</a>, a new releaser for lodash since your current version.</p> </details> <br />

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


<details> <summary>Dependabot commands and options</summary> <br />

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
  • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
  • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
  • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
  • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

You can disable automated security fix PRs for this repo from the Security Alerts page.

</details>

+3 -3

0 comment

1 changed file

dependabot[bot]

pr closed time in 2 months

pull request commentreactjs/reactjs.org

[Issue-3166] Documentation issue fix

Not sure I understand the problem here, since the starter code includes the line const e = React.createElement;

Himachallad

comment created time in 2 months

push eventreactjs/reactjs.org

David Barratt

commit sha 08503a83189631b91c8309b3a8a857c4a8f0015d

Make og:type article for markdown pages (#3146) (#3147)

view details

push time in 2 months

PR merged reactjs/reactjs.org

Make og:type article for markdown pages CLA Signed

Fixes #3146

+9 -2

3 comments

2 changed files

davidbarratt

pr closed time in 2 months

issue closedreactjs/reactjs.org

og:type is hardcoded as website, even for articles

On blog posts like https://reactjs.org/blog/2018/11/27/react-16-roadmap.html the og:type is hard coded as website. https://github.com/reactjs/reactjs.org/blob/3e4f2687c6fd16dbeb075fee1a08c469093dac4e/src/components/TitleAndMetaTags/TitleAndMetaTags.js#L52

This is semantically incorrect and breaks @chickaree https://chickar.ee/reactjs.org/YmxvZy8yMDE4LzExLzI3L3JlYWN0LTE2LXJvYWRtYXAuaHRtbA here is an example from @nytimes of what it should look like: https://chickar.ee/www.nytimes.com/MjAyMC8wNy8yOC9hcnRzL3RlbGV2aXNpb24vZW1teS1ub21pbmVlcy1saXN0Lmh0bWw

If this could be updated for blog posts to be article that would be awesome. :)

closed time in 2 months

davidbarratt

pull request commentreactjs/reactjs.org

Make og:type article for markdown pages

This looks good to me, merging. Looks like we still don't have the previews working so I can't verify this, but I hope you've verified it on your end and made sure it doesn't appear for pages it shouldn't. Thank you very much!

davidbarratt

comment created time in 2 months

issue commentreactjs/reactjs.org

"npx create-react-app" dons't work , why?????

This does seem like a permissions issue. This issue also probably belongs in https://github.com/facebook/create-react-app/issues.

ahmedelamine

comment created time in 2 months

issue closedreactjs/reactjs.org

"npx create-react-app" dons't work , why?????

that is the Err: Error: EPERM: operation not permitted, mkdir 'C:\Users\ahmed' TypeError: Cannot read property 'get' of undefined at errorMessage (C:\Program Files\nodejs\node_modules\npm\lib\utils\error-message.js:38:39) at errorHandler (C:\Program Files\nodejs\node_modules\npm\lib\utils\error-handler.js:201:13) at C:\Program Files\nodejs\node_modules\npm\bin\npm-cli.js:78:20 at cb (C:\Program Files\nodejs\node_modules\npm\lib\npm.js:225:22) at C:\Program Files\nodejs\node_modules\npm\lib\npm.js:263:24 at C:\Program Files\nodejs\node_modules\npm\lib\config\core.js:81:7 at Array.forEach (<anonymous>) at C:\Program Files\nodejs\node_modules\npm\lib\config\core.js:80:13 at f (C:\Program Files\nodejs\node_modules\npm\node_modules\once\once.js:25:25) at afterExtras (C:\Program Files\nodejs\node_modules\npm\lib\config\core.js:171:20) C:\Program Files\nodejs\node_modules\npm\lib\utils\error-handler.js:97 var doExit = npm.config.loaded ? npm.config.get('_exit') : true ^

TypeError: Cannot read property 'loaded' of undefined at exit (C:\Program Files\nodejs\node_modules\npm\lib\utils\error-handler.js:97:27) at process.errorHandler (C:\Program Files\nodejs\node_modules\npm\lib\utils\error-handler.js:216:3) at process.emit (events.js:321:20) at process._fatalException (internal/process/execution.js:164:25) Install for [ 'create-react-app@latest' ] failed with code 7

closed time in 2 months

ahmedelamine

issue commentreactjs/react-codemod

Transform file React-PropTypes-to-prop-types.js does not exist

Please file a new issue @Punith22bravo.

jdwinall-tm

comment created time in 2 months

PR closed reactjs/reactjs.org

w

w

<!--

Thank you for the PR! Contributors like you keep React awesome!

Please see the Contribution Guide for guidelines:

https://github.com/reactjs/reactjs.org/blob/master/CONTRIBUTING.md

If your PR references an existing issue, please add the issue number below

-->

+1 -1

3 comments

1 changed file

Santhoshah

pr closed time in 2 months

pull request commentreactjs/reactjs.org

Update Rollup example for Optimizing Performance

Great to hear! (Also, good feature for rollup to have, very nice)

pioug

comment created time in 2 months

issue commentreactjs/react-codemod

$ is not a function

Oh hmm that’s odd. I’ll think about it this week, will try to run it on a windows machine too.

maraisr

comment created time in 3 months

issue commentreactjs/react-codemod

Error when running rename-unsafe-lifecycles

I'm not doing any active development on this, but I'd be happy to review and land a PR with a fix.

wesleyyee

comment created time in 3 months

issue closedreactjs/react-codemod

Generate `type Props = {...}`

Is there any codemod to generate Props types automatically? Similar to how this linter plugin finds undecalred props.

closed time in 3 months

siderakis

issue commentreactjs/react-codemod

Generate `type Props = {...}`

I don't think this would be something this project would include by default. You could consider using a static type system like flow or typescript, or you could of course write your own codemod that does so. Closing this issue, but happy to discuss if there's widespread interest.

siderakis

comment created time in 3 months

issue commentreactjs/react-codemod

$ is not a function

could you try running this command from outside the repo you want changed? so for example if myproject is the codebase, don't do cd myproject && npx react-codemod, instead run npx react-codemod myproject (I hope that's clear, happy to explain further if I'm not)

maraisr

comment created time in 3 months

pull request commentreactjs/react-codemod

Update update-react-imports with early return

yup, I see it https://github.com/reactjs/react-codemod/commit/cae173b9a425a68afa581c8770fe56f94efc97b1 yay you!

lunaruan

comment created time in 3 months

pull request commentreactjs/react-codemod

Update update-react-imports with early return

git push origin master? or something like that

lunaruan

comment created time in 3 months

pull request commentreactjs/react-codemod

Update update-react-imports with early return

yup, looks like the package got published correctly https://www.npmjs.com/package/react-codemod/v/5.2.2 but you also have to push the commit that's generated to this repo (ie - when you ran npm version patch, it makes a commit that looks like this https://github.com/reactjs/react-codemod/commit/c46e5f23763619201a82e9913766f1572bbbc49c, just push that to this repo directly)

lunaruan

comment created time in 3 months

PR closed reactjs/reactjs.org

Fixed a spelling mistake CLA Signed

<!--

Thank you for the PR! Contributors like you keep React awesome!

Please see the Contribution Guide for guidelines:

https://github.com/reactjs/reactjs.org/blob/master/CONTRIBUTING.md

If your PR references an existing issue, please add the issue number below

-->

+1 -1

3 comments

1 changed file

amoghrajesh

pr closed time in 3 months

pull request commentreactjs/react-codemod

Update update-react-imports with early return

I've merged this, but I'm having trouble publishing this. So I added you as a maintainer on https://www.npmjs.com/package/react-codemod. In your repo, run npm version patch, then npm pub, and then git push.

lunaruan

comment created time in 3 months

push eventreactjs/react-codemod

Luna Ruan

commit sha 3d2216267bddd28cf8f1de60119ad3b92c16c1d7

fixed bugs (#266)

view details

push time in 3 months

PR merged reactjs/react-codemod

Reviewers
Update update-react-imports with early return

Sometimes, jscodeshift will modify files that it touched even though the codemod may not have actually modified any code. Because jscodeshift sometimes doesn't play well with types, this sometimes leads to files being modified unintentionally in strange ways. This PR adds an early return if we know we aren't going to modify any react imports in update-react-imports to avoid these unintentional modifications.

This PR also fixes a bug where we treat import type React from 'react' the same as import React from 'react'.

+15 -1

0 comment

4 changed files

lunaruan

pr closed time in 3 months

issue closedreactjs/reactjs.org

Release Channels page in the docs doesn't have "Previous article" or "Next article" links

https://reactjs.org/docs/release-channels.html

Beginners looking to learn React often start from the beginning of the "Getting started" page (https://reactjs.org/docs/getting-started.html) and progress through the pages by clicking "Next article" at the bottom of each page. This page is missing that link as well as the "Previous article" link. It would be very helpful to add this to the bottom of the page to keep it consistent with the rest of the "getting started" pages.

"CDN Links" (https://reactjs.org/docs/cdn-links.html) has a "Next article" link that goes to "Release Channels".

"Hello World" (https://reactjs.org/docs/hello-world.html) has a "Previous article" link that links to "CDN Links".

This chain in the docs is broken and currently difficult for a beginner to navigate.

closed time in 3 months

arnav-aggarwal

issue commentreactjs/reactjs.org

Release Channels page in the docs doesn't have "Previous article" or "Next article" links

Landed the PR with the fix, closing this issue. It should reflect on the website in a few minutes, please let me know here if it doesn’t. Thanks @sijusamson!

arnav-aggarwal

comment created time in 3 months

push eventreactjs/reactjs.org

Siju Samson

commit sha 1913f358fcf4f8a6a602ddb8797f110b11901814

Release Channels page in the docs doesn't have "Previous article" or "Next article" links => Issue Resolved (#3082)

view details

push time in 3 months

PR merged reactjs/reactjs.org

Release Channels page in the docs doesn't have "Previous article" or "Next article" links CLA Signed

This is a PR for bug #3068

<!--

Thank you for the PR! Contributors like you keep React awesome!

Please see the Contribution Guide for guidelines:

https://github.com/reactjs/reactjs.org/blob/master/CONTRIBUTING.md

If your PR references an existing issue, please add the issue number below

-->

+2 -0

0 comment

1 changed file

sijusamson

pr closed time in 3 months

issue commentreactjs/reactjs.org

[removed]

I'm not sure why you're spamming the issues section. I'm going to lock these issues, but fair warning, if you keep doing this, I"m going to ban your from the project.

azaruiz

comment created time in 3 months

issue commentreactjs/reactjs.org

gh-pages -d build events.js:174. throw er; // Unhandled 'error' event

Why don't you file this under https://github.com/tschaub/gh-pages/issues? It's not clear why you'd file this under the documentation project for react.

ahmedgulabkhan

comment created time in 3 months

PR closed reactjs/reactjs.org

Update hooks-custom.md

<!--

Thank you for the PR! Contributors like you keep React awesome!

Please see the Contribution Guide for guidelines:

https://github.com/reactjs/reactjs.org/blob/master/CONTRIBUTING.md

If your PR references an existing issue, please add the issue number below

-->

+2 -2

2 comments

1 changed file

hiteshagja

pr closed time in 3 months

pull request commentreactjs/reactjs.org

Update hooks-custom.md

This doesn't seem right, the component still receives props as expected.

hiteshagja

comment created time in 3 months

issue closedreactjs/reactjs.org

npm

The version 16.13.1 in react, there is the function mapIntoArray in the source code, why the react installed by npm is not in react.development.js

closed time in 3 months

shanhh

issue commentreactjs/reactjs.org

npm

Closing, but happy to discuss if intentions are made clear.

shanhh

comment created time in 3 months

issue closedreactjs/reactjs.org

add .htaccess file in public folder

.htaccess file in public folder is required with the following content:

<IfModule mod_rewrite.c>
    <IfModule mod_negotiation.c>
        Options -MultiViews -Indexes
    </IfModule>

    RewriteEngine On

    # Handle Authorization Header
    RewriteCond %{HTTP:Authorization} .
    RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]

    # Redirect Trailing Slashes If Not A Folder...
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteCond %{REQUEST_URI} (.+)/$
    RewriteRule ^ %1 [L,R=301]

    # Send Requests To Front Controller...
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteRule ^ index.html [L]
</IfModule>

closed time in 3 months

SCR-IR

issue commentreactjs/reactjs.org

add .htaccess file in public folder

Closing, but happy to discuss if intentions are made clear.

SCR-IR

comment created time in 3 months

issue closedreactjs/reactjs.org

Bing

[removed]

closed time in 3 months

azaruiz

issue closedreactjs/reactjs.org

amr_aza@hotmail.com

amr_aza@hotmail.com

Originally posted by @azaruiz in https://github.com/reactjs/reactjs.org/issues/3069#issuecomment-651531019

closed time in 3 months

azaruiz

issue closedreactjs/react-codemod

unable to publish react-codemod to npm

There's a problem with npm, every time I've tried to publish the latest version, I get a 404 error (??!)

npm ERR! code E404
npm ERR! 404 Not Found - PUT https://registry.npmjs.org/react-codemod - Not found
npm ERR! 404 
npm ERR! 404  'react-codemod@5.2.1' is not in the npm registry.
npm ERR! 404 You should bug the author to publish it (or use the name yourself!)
npm ERR! 404 
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, http url, or git url.

I'm giving up at this point. If someone else with publish rights could try publishing this, that would be great.

Of note, this is critical because it contains @lunaruan's PR https://github.com/reactjs/react-codemod/pull/262 for update-react-import.

cc @cpojer, since I know he has publish rights. If either he could do a publish, or give publish rights to someone else on the react team and they could try it themselves.

closed time in 3 months

threepointone

issue commentreactjs/react-codemod

unable to publish react-codemod to npm

Miss you bud, thanks for the assist.

threepointone

comment created time in 3 months

issue openedreactjs/react-codemod

unable to publish react-codemod to npm

There's a problem with npm, every time I've tried to publish the latest version, I get a 404 error (??!)

npm ERR! code E404
npm ERR! 404 Not Found - PUT https://registry.npmjs.org/react-codemod - Not found
npm ERR! 404 
npm ERR! 404  'react-codemod@5.2.1' is not in the npm registry.
npm ERR! 404 You should bug the author to publish it (or use the name yourself!)
npm ERR! 404 
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, http url, or git url.

I'm giving up at this point. If someone else with publish rights could try publishing this, that would be great.

Of note, this is critical because it contains @lunaruan's PR https://github.com/reactjs/react-codemod/pull/262 for update-react-import.

cc @cpojer, since I know he has publish rights. If either he could do a publish, or give publish rights to someone else on the react team and they could try it themselves.

created time in 3 months

push eventreactjs/react-codemod

Sunil Pai

commit sha da7925106ede5f660c8fade03f049d73caffe386

5.2.0

view details

Sunil Pai

commit sha c46e5f23763619201a82e9913766f1572bbbc49c

5.2.1

view details

push time in 3 months

startedfoambubble/foam

started time in 3 months

issue openedreactjs/react-codemod

package react-codemod with ncc

This would avoid issues like https://github.com/reactjs/react-codemod/issues/249

created time in 3 months

push eventreactjs/react-codemod

Sunil Pai

commit sha 4e520606118ed69c1de8210234ca787af634d490

yarn upgrade

view details

push time in 3 months

push eventreactjs/react-codemod

dependabot[bot]

commit sha 582d05e4c17c699d2cf317f4748e489fb7d98f43

Bump acorn from 5.7.3 to 5.7.4 (#256) Bumps [acorn](https://github.com/acornjs/acorn) from 5.7.3 to 5.7.4. - [Release notes](https://github.com/acornjs/acorn/releases) - [Commits](https://github.com/acornjs/acorn/compare/5.7.3...5.7.4) Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

view details

push time in 3 months

PR merged reactjs/react-codemod

Bump acorn from 5.7.3 to 5.7.4 dependencies

Bumps acorn from 5.7.3 to 5.7.4. <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/acornjs/acorn/commit/6370e90067552022710190319cbbbd8c43001957"><code>6370e90</code></a> Mark version 5.7.4</li> <li><a href="https://github.com/acornjs/acorn/commit/fbc15b1344f6dfb992f67b4bbf1357436247c8a0"><code>fbc15b1</code></a> More rigorously check surrogate pairs in regexp validator</li> <li>See full diff in <a href="https://github.com/acornjs/acorn/compare/5.7.3...5.7.4">compare view</a></li> </ul> </details> <br />

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


<details> <summary>Dependabot commands and options</summary> <br />

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
  • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
  • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
  • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
  • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

You can disable automated security fix PRs for this repo from the Security Alerts page.

</details>

+3 -3

0 comment

1 changed file

dependabot[bot]

pr closed time in 3 months

fork threepointone/foam

A personal knowledge management and sharing system for VSCode

https://foambubble.github.io/foam

fork in 3 months

issue commentfacebook/react

why there aren't webpack.config.dev.js and webpack.config.prod.js files in the config folder?

You should file this issue at the create-react-app repo https://github.com/facebook/create-react-app/issues.

farhadibehnam

comment created time in 3 months

issue closedreactjs/reactjs.org

Scrolling through the guides on the right hand panel is broken

Scrolling through the guides on the right hand panel is broken on reactjs.org is broken. Please fix

closed time in 3 months

kusiroll

issue commentreactjs/reactjs.org

Scrolling through the guides on the right hand panel is broken

Closing this issue, happy to reopen if you can explain and/or show a screenshot/gif of what exactly is wrong.

kusiroll

comment created time in 3 months

issue commentreactjs/reactjs.org

add .htaccess file in public folder

Why?

SCR-IR

comment created time in 3 months

PR closed reactjs/reactjs.org

Create try using fork -I amm teacher you dont need to save my pull request

try to use fork!

I am a teacher it was only a exercise for the pupils! thank you! don't save my changes!!!!!!!!!!

+3 -0

1 comment

1 changed file

sarihuminer

pr closed time in 3 months

issue commentreactjs/reactjs.org

npm

It's not clear what you want, could you be clearer? Do you want to be able to use that function? It's not exposed for external usage.

shanhh

comment created time in 3 months

more