Skip to content

Commit

Permalink
Revert "use esm syntax"
Browse files Browse the repository at this point in the history
This reverts commit a52375a.
  • Loading branch information
Drew-Daniels committed Aug 4, 2024
1 parent a52375a commit 2bf6c02
Show file tree
Hide file tree
Showing 9 changed files with 16 additions and 21 deletions.
1 change: 1 addition & 0 deletions apps/iframe-react-app/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,6 @@
"sourceRoot": "apps/iframe-react-app/src",
"projectType": "application",
"tags": [],
"// targets": "to see all targets run: nx show project iframe-react-app --web",
"targets": {}
}
1 change: 1 addition & 0 deletions apps/parent-react-app/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,6 @@
"sourceRoot": "apps/parent-react-app/src",
"projectType": "application",
"tags": [],
"// targets": "to see all targets run: nx show project parent-react-app --web",
"targets": {}
}
2 changes: 1 addition & 1 deletion eslint.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ module.exports = [
files: ['**/*.ts', '**/*.tsx', '**/*.js', '**/*.jsx'],
rules: {
'@nx/enforce-module-boundaries': [
'warn',
'error',
{
enforceBuildableLibDependency: true,
allow: [],
Expand Down
13 changes: 4 additions & 9 deletions libs/core/eslint.config.js
Original file line number Diff line number Diff line change
@@ -1,18 +1,13 @@
import { FlatCompat } from '@eslint/eslintrc';
import baseConfig from "../../eslint.config.js";
import js from "@eslint/js";
import path from 'path';
import { fileURLToPath } from 'url';

const __filename = fileURLToPath(import.meta.url);
const __dirname = path.dirname(__filename);
const { FlatCompat } = require('@eslint/eslintrc');
const baseConfig = require('../../eslint.config.js');
const js = require('@eslint/js');

const compat = new FlatCompat({
baseDirectory: __dirname,
recommendedConfig: js.configs.recommended,
});

export default [
module.exports = [
...baseConfig,
{
files: ['**/*.ts', '**/*.tsx', '**/*.js', '**/*.jsx'],
Expand Down
2 changes: 1 addition & 1 deletion libs/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"dependencies": {
"tslib": "^2.3.0"
},
"type": "module",
"type": "commonjs",
"main": "./src/index.js",
"typings": "./src/index.d.ts",
"private": true
Expand Down
2 changes: 2 additions & 0 deletions libs/core/src/lib/core.spec.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import { Parent, IFrame } from "./core";

describe('Parent', () => {
it.todo('should work');
});
Expand Down
13 changes: 4 additions & 9 deletions libs/react/eslint.config.js
Original file line number Diff line number Diff line change
@@ -1,18 +1,13 @@
import { FlatCompat } from '@eslint/eslintrc';
import baseConfig from '../../eslint.config.js';
import js from '@eslint/js';
import path from 'path';
import { fileURLToPath } from 'url';

const __filename = fileURLToPath(import.meta.url);
const __dirname = path.dirname(__filename);
const { FlatCompat } = require('@eslint/eslintrc');
const baseConfig = require('../../eslint.config.js');
const js = require('@eslint/js');

const compat = new FlatCompat({
baseDirectory: __dirname,
recommendedConfig: js.configs.recommended,
});

export default [
module.exports = [
...baseConfig,
...compat.extends('plugin:@nx/react'),
{
Expand Down
1 change: 0 additions & 1 deletion libs/react/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
"version": "0.0.1",
"main": "./index.js",
"types": "./index.d.ts",
"type": "module",
"exports": {
".": {
"import": "./index.mjs",
Expand Down
2 changes: 2 additions & 0 deletions libs/react/src/lib/react.spec.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import { useIFrame, useParent } from "./react";

describe('useParent', () => {
it.todo('should work');
});
Expand Down

0 comments on commit 2bf6c02

Please sign in to comment.