Files
zeekay 169927b78b refactor: strip duplicate pkgs, consume @l.x/* from npm — keep only pkgs/wallet (canonical @luxfi/wallet bones)
- Delete pkgs/{analytics,api,config,eslint-config,gating,lx,notifications,
  prices,sessions,ui,utilities} — all identical to ~/work/lux/exchange
  canonical (MD5-matched). Now published to npm at @l.x/*; consume from
  there instead of vendoring.
- pkgs/wallet remains — this IS @luxfi/wallet (the uniswap-style extension
  + mobile wallet bones). Published at 1.0.10.
- Rewrite 3553 bare-path imports (uniswap/src/, ui/src/, utilities/src/,
  lx/src/, lux/src/) → explicit @l.x/* across 725 files.
- apps/{extension,mobile}/package.json: workspace:^ → npm ^versions for
  all @l.x/* / @luxfi/eslint-config; only @luxfi/wallet stays workspace.
- apps/{extension,mobile}/.eslintrc.js: RULES_DIR → node_modules/@l.x/lx/eslint_rules.

~315K line deletion. One canonical home: ~/work/lux/exchange.
2026-04-23 17:58:21 -07:00

67 lines
2.0 KiB
JavaScript

const rulesDirPlugin = require('eslint-plugin-rulesdir')
rulesDirPlugin.RULES_DIR = '../../node_modules/@l.x/lx/eslint_rules'
module.exports = {
root: true,
extends: ['@luxfi/eslint-config/mobile'],
plugins: ['rulesdir'],
ignorePatterns: [
'.storybook/storybook.requires.ts',
'!.maestro', // Don't ignore .maestro directory
'!.maestro/**', // Don't ignore files in .maestro
],
parserOptions: {
project: 'tsconfig.eslint.json',
tsconfigRootDir: __dirname,
ecmaFeatures: {
jsx: true,
},
ecmaVersion: 2018,
sourceType: 'module',
},
overrides: [
{
files: ['index.js', 'src/index.ts', 'src/polyfills/index.ts', 'src/test/fixtures/*'],
rules: {
'check-file/no-index': 'off',
},
},
{
files: ['*.ts', '*.tsx'],
rules: {
'no-relative-import-paths/no-relative-import-paths': [
'error',
{
allowSameFolder: false,
prefix: 'src',
},
],
},
},
{
files: ['.maestro/scripts/**/*.ts'],
rules: {
// Maestro scripts have different import requirements
'no-relative-import-paths/no-relative-import-paths': 'off',
// Allow console.log for Maestro scripts (needed for metrics output)
'no-console': 'off',
// These scripts run in GraalJS environment, not React Native
'react-native/no-unused-styles': 'off',
'react-native/no-color-literals': 'off',
// Triple-slash references are needed for globals in Maestro environment
'@typescript-eslint/triple-slash-reference': 'off',
// Don't require React in scope for these non-React files
'react/react-in-jsx-scope': 'off',
// Allow any for error handling in compile script
'@typescript-eslint/no-explicit-any': 'warn',
// These are utility modules that may not all be used immediately
'import/no-unused-modules': 'off',
},
},
],
rules: {
'rulesdir/i18n': 'error',
'rulesdir/no-redux-modals': 'error',
},
}