1
0
mirror of https://github.com/spacebarchat/client.git synced 2024-11-21 18:02:32 +01:00

esbuild + initial dependencies

This commit is contained in:
Puyodead1 2023-03-20 17:21:32 -04:00
parent f0e6048a20
commit 3146f73cb7
No known key found for this signature in database
GPG Key ID: A4FA4FEC0DD353FC
7 changed files with 10638 additions and 40 deletions

5
craco.config.js Normal file
View File

@ -0,0 +1,5 @@
const CracoEsbuildPlugin = require("craco-esbuild");
module.exports = {
plugins: [{ plugin: CracoEsbuildPlugin }],
};

View File

@ -10,9 +10,19 @@
"@types/node": "^16.18.16",
"@types/react": "^18.0.28",
"@types/react-dom": "^18.0.11",
"formik": "^2.2.9",
"mobx": "^6.8.0",
"react": "^18.2.0",
"react-advanced-cropper": "^0.18.0",
"react-colorful": "^5.6.1",
"react-dom": "^18.2.0",
"react-loading-skeleton": "^3.2.0",
"react-responsive": "^9.0.2",
"react-scripts": "5.0.1",
"react-spinkit": "^3.0.0",
"slate": "^0.91.4",
"slate-react": "^0.92.0",
"styled-components": "^5.3.9",
"typescript": "^4.9.5",
"web-vitals": "^2.1.4"
},
@ -39,5 +49,9 @@
"last 1 firefox version",
"last 1 safari version"
]
},
"devDependencies": {
"@craco/craco": "^7.1.0",
"craco-esbuild": "^0.5.2"
}
}

10614
pnpm-lock.yaml Normal file

File diff suppressed because it is too large Load Diff

View File

@ -1,9 +0,0 @@
import React from 'react';
import { render, screen } from '@testing-library/react';
import App from './App';
test('renders learn react link', () => {
render(<App />);
const linkElement = screen.getByText(/learn react/i);
expect(linkElement).toBeInTheDocument();
});

View File

@ -1,19 +1,13 @@
import React from 'react';
import ReactDOM from 'react-dom/client';
import './index.css';
import App from './App';
import reportWebVitals from './reportWebVitals';
import React from "react";
import ReactDOM from "react-dom/client";
import App from "./App";
import "./index.css";
const root = ReactDOM.createRoot(
document.getElementById('root') as HTMLElement
document.getElementById("root") as HTMLElement
);
root.render(
<React.StrictMode>
<App />
</React.StrictMode>
);
// If you want to start measuring performance in your app, pass a function
// to log results (for example: reportWebVitals(console.log))
// or send to an analytics endpoint. Learn more: https://bit.ly/CRA-vitals
reportWebVitals();

View File

@ -1,15 +0,0 @@
import { ReportHandler } from 'web-vitals';
const reportWebVitals = (onPerfEntry?: ReportHandler) => {
if (onPerfEntry && onPerfEntry instanceof Function) {
import('web-vitals').then(({ getCLS, getFID, getFCP, getLCP, getTTFB }) => {
getCLS(onPerfEntry);
getFID(onPerfEntry);
getFCP(onPerfEntry);
getLCP(onPerfEntry);
getTTFB(onPerfEntry);
});
}
};
export default reportWebVitals;

View File

@ -1,5 +0,0 @@
// jest-dom adds custom jest matchers for asserting on DOM nodes.
// allows you to do things like:
// expect(element).toHaveTextContent(/react/i)
// learn more: https://github.com/testing-library/jest-dom
import '@testing-library/jest-dom';