Skip to content

Commit

Permalink
lint fix
Browse files Browse the repository at this point in the history
  • Loading branch information
hamid-Ft committed Nov 25, 2023
1 parent 519e045 commit 53c16a7
Show file tree
Hide file tree
Showing 21 changed files with 391 additions and 366 deletions.
2 changes: 1 addition & 1 deletion .eslintrc.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ module.exports = {
'prettier',
],
ignorePatterns: ['dist', '.eslintrc.cjs'],
parser: '@typescript-eslint/np',
parser: '@typescript-eslint/parser',
parserOptions: {
project: './tsconfig.json',
ecmaFeatures: {
Expand Down
19 changes: 10 additions & 9 deletions .prettierrc.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
{
"printWidth": 80,
"tabWidth": 4,
"semi": true,
"singleQuote": true,
"trailingComma": "all",
"bracketSpacing": true,
"bracketSameLine": true,
"arrowParens": "avoid",
"htmlWhitespaceSensitivity": "css"
"printWidth": 80,
"tabWidth": 4,
"semi": true,
"singleQuote": true,
"trailingComma": "all",
"bracketSpacing": true,
"bracketSameLine": true,
"arrowParens": "avoid",
"htmlWhitespaceSensitivity": "css",
"endOfLine": "auto"
}
48 changes: 24 additions & 24 deletions jest.config.ts
Original file line number Diff line number Diff line change
@@ -1,31 +1,31 @@
export default {

Check failure on line 1 in jest.config.ts

View workflow job for this annotation

GitHub Actions / ci (ubuntu-latest, 20)

Expected linebreaks to be 'CRLF' but found 'LF'
preset: 'ts-jest', // Presetting to typescript jest
testEnvironment: 'jsdom', // Testing environment is jsdom
preset: 'ts-jest', // Presetting to typescript jest

Check failure on line 2 in jest.config.ts

View workflow job for this annotation

GitHub Actions / ci (ubuntu-latest, 20)

Expected linebreaks to be 'CRLF' but found 'LF'
testEnvironment: 'jsdom', // Testing environment is jsdom

Check failure on line 3 in jest.config.ts

View workflow job for this annotation

GitHub Actions / ci (ubuntu-latest, 20)

Expected linebreaks to be 'CRLF' but found 'LF'

Check failure on line 4 in jest.config.ts

View workflow job for this annotation

GitHub Actions / ci (ubuntu-latest, 20)

Expected linebreaks to be 'CRLF' but found 'LF'
transform: {
'^.+\\.tsx?$': [
// If the file is a typescript or typescript jsx file transform it using ts-jest
'ts-jest',
transform: {

Check failure on line 5 in jest.config.ts

View workflow job for this annotation

GitHub Actions / ci (ubuntu-latest, 20)

Expected linebreaks to be 'CRLF' but found 'LF'
'^.+\\.tsx?$': [

Check failure on line 6 in jest.config.ts

View workflow job for this annotation

GitHub Actions / ci (ubuntu-latest, 20)

Expected linebreaks to be 'CRLF' but found 'LF'
// If the file is a typescript or typescript jsx file transform it using ts-jest

Check failure on line 7 in jest.config.ts

View workflow job for this annotation

GitHub Actions / ci (ubuntu-latest, 20)

Expected linebreaks to be 'CRLF' but found 'LF'
'ts-jest',

Check failure on line 8 in jest.config.ts

View workflow job for this annotation

GitHub Actions / ci (ubuntu-latest, 20)

Expected linebreaks to be 'CRLF' but found 'LF'

Check failure on line 9 in jest.config.ts

View workflow job for this annotation

GitHub Actions / ci (ubuntu-latest, 20)

Expected linebreaks to be 'CRLF' but found 'LF'
{
tsconfig: { module: 'es2020' }, // Using ECMAScript 2020 module specification
{

Check failure on line 10 in jest.config.ts

View workflow job for this annotation

GitHub Actions / ci (ubuntu-latest, 20)

Expected linebreaks to be 'CRLF' but found 'LF'
tsconfig: { module: 'es2020' }, // Using ECMAScript 2020 module specification

BabelConfig: {
configFile: false, // No configuration file for Babel
BabelConfig: {
configFile: false, // No configuration file for Babel

// Presetting to @babel/preset-env with targets and @babel/preset-typescript
presets: [
['@babel/preset-env', { targets: { node: 'current' } }],
'@babel/preset-typescript',
],
},
},
],
},
// Presetting to @babel/preset-env with targets and @babel/preset-typescript
presets: [
['@babel/preset-env', { targets: { node: 'current' } }],
'@babel/preset-typescript',
],
},
},
],
},

// For certain file types, mock file or identity object proxy is used
moduleNameMapper: {
'\\.(gif|ttf|eot|svg|png)$': '<rootDir>/test/__mocks__/fileMock.js',
'\\.(css|less|sass|scss)$': 'identity-obj-proxy',
},
// For certain file types, mock file or identity object proxy is used
moduleNameMapper: {
'\\.(gif|ttf|eot|svg|png)$': '<rootDir>/test/__mocks__/fileMock.js',
'\\.(css|less|sass|scss)$': 'identity-obj-proxy',
},
};
10 changes: 3 additions & 7 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 3 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@
"jest-environment-jsdom": "^29.7.0",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"typescript": "^5.3.2",
"vite": "^4.4.5"
"vite": "^4.4.5",
"vite-plugin-environment": "^1.1.3"
},
"devDependencies": {
"@testing-library/jest-dom": "^6.1.4",
Expand Down Expand Up @@ -66,8 +66,6 @@
"prettier-eslint": "^16.1.2",
"tailwindcss": "^3.3.5",
"ts-jest": "^29.1.1",
"ts-node": "^10.9.1",
"typescript": "^5.2.2",
"vite-plugin-environment": "^1.1.3"
"ts-node": "^10.9.1"
}
}
8 changes: 4 additions & 4 deletions postcss.config.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
export default {
plugins: {
tailwindcss: {},
autoprefixer: {},
},
plugins: {
tailwindcss: {},
autoprefixer: {},
},
};
4 changes: 2 additions & 2 deletions src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import AudioRecorder from './components/AudioRecorder';
import './App.css';

function App() {
return <AudioRecorder />;
return <AudioRecorder />;
}

export default App;
export default App;
6 changes: 3 additions & 3 deletions src/__tests__/App.spec.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ import '@testing-library/jest-dom';
global.MediaStream = jest.fn();

test('demo', () => {
expect(true).toBe(true);
expect(true).toBe(true);
});

test('Renders the main page', () => {
render(<App />);
expect(true).toBeTruthy();
render(<App />);
expect(true).toBeTruthy();
});
Loading

0 comments on commit 53c16a7

Please sign in to comment.