Skip to content

Commit

Permalink
"type": "module"
Browse files Browse the repository at this point in the history
  • Loading branch information
ericclemmons committed Apr 26, 2022
1 parent c66a4eb commit 65faad2
Show file tree
Hide file tree
Showing 11 changed files with 13 additions and 12 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { ClickToComponent as Component } from './src/ClickToComponent.mjs'
import { ClickToComponent as Component } from './src/ClickToComponent.js'

export const ClickToComponent =
process.env.NODE_ENV === 'development' ? Component : () => null
1 change: 1 addition & 0 deletions packages/click-to-react-component/package.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{
"type": "module",
"name": "click-to-react-component",
"version": "1.0.1",
"description": "Option+Click your React components in your browser to open the source file in VS Code",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import { FloatingPortal } from '@floating-ui/react-dom-interactions'
import { html } from 'htm/react'
import * as React from 'react'

import { ContextMenu } from './ContextMenu.mjs'
import { getPathToSource } from './getPathToSource.mjs'
import { getSourceForElement } from './getSourceForElement.mjs'
import { ContextMenu } from './ContextMenu.js'
import { getPathToSource } from './getPathToSource.js'
import { getSourceForElement } from './getSourceForElement.js'

export const State = /** @type {const} */ ({
IDLE: 'IDLE',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@ import { html } from 'htm/react'
import * as React from 'react'
import mergeRefs from 'react-merge-refs'

import { getDisplayNameForInstance } from './getDisplayNameFromReactInstance.mjs'
import { getPathToSource } from './getPathToSource.mjs'
import { getPropsForInstance } from './getPropsForInstance.mjs'
import { getReactInstancesForElement } from './getReactInstancesForElement.mjs'
import { getSourceForInstance } from './getSourceForInstance.mjs'
import { getDisplayNameForInstance } from './getDisplayNameFromReactInstance.js'
import { getPathToSource } from './getPathToSource.js'
import { getPropsForInstance } from './getPropsForInstance.js'
import { getReactInstancesForElement } from './getReactInstancesForElement.js'
import { getSourceForInstance } from './getSourceForInstance.js'

export const ContextMenu = React.forwardRef(
(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* @typedef {import('react-reconciler').Fiber} Fiber
*/

import { getReactInstanceForElement } from './getReactInstanceForElement.mjs'
import { getReactInstanceForElement } from './getReactInstanceForElement.js'

export function getReactInstancesForElement(
/** @type {HTMLElement} */
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { getReactInstanceForElement } from './getReactInstanceForElement.mjs'
import { getSourceForInstance } from './getSourceForInstance.mjs'
import { getReactInstanceForElement } from './getReactInstanceForElement.js'
import { getSourceForInstance } from './getSourceForInstance.js'

/**
* @typedef {import('react-reconciler').Fiber} Fiber
Expand Down

0 comments on commit 65faad2

Please sign in to comment.