Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
147 changes: 147 additions & 0 deletions .eslintrc.js
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what is this file? wouldn't we like it to be .gitignored?

Original file line number Diff line number Diff line change
@@ -0,0 +1,147 @@
const baseExtends = ['eslint:recommended', 'prettier', 'plugin:react/recommended', 'plugin:react-hooks/recommended'];

module.exports = {
parser: '@typescript-eslint/parser',
parserOptions: {
ecmaVersion: 2020,
sourceType: 'module',
ecmaFeatures: {
jsx: true,
},
},
settings: {
react: { version: '16' },
},
plugins: ['prettier', 'jest', '@typescript-eslint', 'no-only-tests', 'react-hooks', 'react-hooks-static-deps'],
extends: baseExtends,
env: {
node: true,
es2020: true,
'jest/globals': true,
},
rules: {
strict: 0,
'react/prop-types': 0,
'prettier/prettier': [
'error',
{
printWidth: 120,
semi: true,
singleQuote: true,
tabWidth: 4,
trailingComma: 'all',
useTabs: false,
endOfLine: 'lf',
propTypes: false,
bracketSpacing: true,
},
],
'react/no-unescaped-entities': 0,
'react/display-name': 'off',
'no-prototype-builtins': 'off',
'no-empty': 'off',
'react-hooks/exhaustive-deps': 'off',
'react-hooks-static-deps/exhaustive-deps': [
'warn',
{
// These hooks are defined to be static for react-hooks/exhaustive-deps eslint rule.
// It means that they are stable and shouldn't be added to the dependency array.
// See: https://www.npmjs.com/package/eslint-plugin-react-hooks-static-deps
staticHooks: {
useStoreStatic: true,
useStoreActions: true,
useIsMounted: true,
useGlobalContext: {
getOpenedModals: true,
showModal: true,
hideModal: true,
hideAllModals: true,
startLoader: true,
stopLoader: true,
showErrorToast: true,
showSuccessToast: true,
},
useGTMDispatch: true,
useGtm: true,
useEventTargets: true,
useInternalEventReporter: true,
useEventReporter: true,
useStateInRef: true,
useHistory: true,
useIntegrations: true,
useIoContext: true,
useServiceTemplateApi: true,
useBillCommands: true,
useVoidInvoice: true,
useApproveAmendments: true,
useApproveCharges: true,
useApproveInvoices: true,
useUpdateProgressStatus: true,
useCopyDirectLink: true,
useSendReminder: true,
useDebouncedLogSearchToBI: true,
useRelationshipDraftApi: true,
usePusher: true,
usePusherBusinessChannel: { getChannel: true },
useForm: true,
useFormContext: true,
useQboIntegration: {
fetchAndGetQboIntegration: true,
},
useStateFromUrl: {
changeUrlState: true,
},
useHomePage: {
setHidden: true,
},
useOpenCopyLinkModal: true,
useSignal: [false, true],
useRestfulWrapper: {
refresh: true,
},
},
},
],
},
overrides: [
{
files: ['**/*.ts', '**/*.tsx'],
extends: [...baseExtends, 'plugin:@typescript-eslint/recommended'],
rules: {
'no-unused-vars': 'off',
'react/prop-types': 'off',
'react/display-name': 'off',
'@typescript-eslint/no-empty-function': 'off',
'no-only-tests/no-only-tests': 'error',
'@typescript-eslint/no-non-null-assertion': 'off',
'@typescript-eslint/no-explicit-any': 'warn',
'@typescript-eslint/no-unused-vars': [
'error',
{
argsIgnorePattern: '^_',
varsIgnorePattern: '^_',
},
],
'react/no-unescaped-entities': 'off',
'react-hooks/exhaustive-deps': 'off',
},
},
],
globals: {
window: true,
navigator: true,
document: true,
history: true,
FileReader: true,
performance: true,
location: true,
localStorage: true,
Cypress: true,
cy: true,
Sentry: true,
alert: true,
File: true,
Blob: true,
fetch: true,
},
};
2 changes: 2 additions & 0 deletions .gitignore
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

textfiles must end by a newline !!!

Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
/_agent.js
/node_modules
36 changes: 0 additions & 36 deletions get_class_instances.js

This file was deleted.

4 changes: 0 additions & 4 deletions get_object_address.js

This file was deleted.

4 changes: 0 additions & 4 deletions get_process_modules.js

This file was deleted.

17 changes: 0 additions & 17 deletions interactive.js

This file was deleted.

Loading