Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Warning on quasar dev execution #10947

Closed
2 tasks done
afnan opened this issue Oct 11, 2021 · 6 comments
Closed
2 tasks done

Warning on quasar dev execution #10947

afnan opened this issue Oct 11, 2021 · 6 comments
Labels
Qv2 🔝 Quasar v2 issues

Comments

@afnan
Copy link

afnan commented Oct 11, 2021

Describe the bug
A clear and concise description of what the bug is.

TypeError: CLIEngine is not a constructor
TypeError: CLIEngine is not a constructor
    at createEsLintReporter (C:\Users\abashir\Documents\Development\Tehqeeq_Front_End\node_modules\fork-ts-checker-webpack-plugin\lib\eslint-reporter\reporter\EsLintReporter.js:22:20)
    at Object.<anonymous> (C:\Users\abashir\Documents\Development\Tehqeeq_Front_End\node_modules\fork-ts-checker-webpack-plugin\lib\reporter\reporter-rpc\ReporterRpcService.js:21:30)
    at Generator.next (<anonymous>)
    at C:\Users\abashir\Documents\Development\Tehqeeq_Front_End\node_modules\fork-ts-checker-webpack-plugin\lib\reporter\reporter-rpc\ReporterRpcService.js:8:71
    at new Promise (<anonymous>)
    at __awaiter (C:\Users\abashir\Documents\Development\Tehqeeq_Front_End\node_modules\fork-ts-checker-webpack-plugin\lib\reporter\reporter-rpc\ReporterRpcService.js:4:12)
    at C:\Users\abashir\Documents\Development\Tehqeeq_Front_End\node_modules\fork-ts-checker-webpack-plugin\lib\reporter\reporter-rpc\ReporterRpcService.js:19:88
    at Object.<anonymous> (C:\Users\abashir\Documents\Development\Tehqeeq_Front_End\node_modules\fork-ts-checker-webpack-plugin\lib\rpc\RpcService.js:23:38)
    at Generator.next (<anonymous>)
    at C:\Users\abashir\Documents\Development\Tehqeeq_Front_End\node_modules\fork-ts-checker-webpack-plugin\lib\rpc\RpcService.js:8:71
TypeError: CLIEngine is not a constructor
TypeError: CLIEngine is not a constructor
    at createEsLintReporter (C:\Users\abashir\Documents\Development\Tehqeeq_Front_End\node_modules\fork-ts-checker-webpack-plugin\lib\eslint-reporter\reporter\EsLintReporter.js:22:20)
    at Object.<anonymous> (C:\Users\abashir\Documents\Development\Tehqeeq_Front_End\node_modules\fork-ts-checker-webpack-plugin\lib\reporter\reporter-rpc\ReporterRpcService.js:21:30)
    at Generator.next (<anonymous>)
    at C:\Users\abashir\Documents\Development\Tehqeeq_Front_End\node_modules\fork-ts-checker-webpack-plugin\lib\reporter\reporter-rpc\ReporterRpcService.js:8:71
    at new Promise (<anonymous>)
    at __awaiter (C:\Users\abashir\Documents\Development\Tehqeeq_Front_End\node_modules\fork-ts-checker-webpack-plugin\lib\reporter\reporter-rpc\ReporterRpcService.js:4:12)
    at C:\Users\abashir\Documents\Development\Tehqeeq_Front_End\node_modules\fork-ts-checker-webpack-plugin\lib\reporter\reporter-rpc\ReporterRpcService.js:19:88
    at Object.<anonymous> (C:\Users\abashir\Documents\Development\Tehqeeq_Front_End\node_modules\fork-ts-checker-webpack-plugin\lib\rpc\RpcService.js:23:38)
    at Generator.next (<anonymous>)
    at C:\Users\abashir\Documents\Development\Tehqeeq_Front_End\node_modules\fork-ts-checker-webpack-plugin\lib\rpc\RpcService.js:8:71

To Reproduce
Happened after upgrading to the following

"dependencies": {
    "@quasar/extras": "^1.11.2",
    "axios": "^0.22.0",
    "core-js": "^3.18.2",
    "quasar": "^2.1.1",
    "vue3-mindmap": "^0.5.8",
    "vuex": "^4.0.1"
  },
  "devDependencies": {
    "@babel/eslint-parser": "^7.15.8",
    "@quasar/app": "^3.1.3",
    "@types/node": "^16.10.3",
    "@typescript-eslint/eslint-plugin": "^4.33.0",
    "@typescript-eslint/parser": "^4.33.0",
    "eslint": "^8.0.0",
    "eslint-config-airbnb-base": "^14.0.0",
    "eslint-plugin-import": "^2.20.1",
    "eslint-plugin-vue": "^7.19.1"
  },
  "browserslist": [
    "last 10 Chrome versions",
    "last 10 Firefox versions",
    "last 4 Edge versions",
    "last 7 Safari versions",
    "last 8 Android versions",
    "last 8 ChromeAndroid versions",
    "last 8 FirefoxAndroid versions",
    "last 10 iOS versions",
    "last 5 Opera versions"
  ],
  "engines": {
    "node": ">= 12.22.1",
    "npm": ">= 6.13.4",
    "yarn": ">= 1.21.1"
  }

Quasar mode:

  • SPA

Tested on:

  • SPA

The app works fine though

Thanks

@afnan afnan added the Qv2 🔝 Quasar v2 issues label Oct 11, 2021
@rstoenescu
Copy link
Member

rstoenescu commented Oct 11, 2021 via email

@rstoenescu
Copy link
Member

I remember that at some point in time the official starter kit had a "CLIEngine" reference for the linter in quasar.conf.js.
But if you updated the linter (which is most likely), then you also need to update the linter config yourself (or create a new Quasar app and copy the linting from there).

Please feel free to reopen if I missed anything.

@afnan
Copy link
Author

afnan commented Oct 12, 2021

hen you also need to update the linter config yourself

Thank you for your detailed reply. My quasar conf file is as follow. I have tried installing the new quasar app and compared the conf file. They are the same. Also, I get with new install.


yarn run v1.22.11
$ eslint --ext .js,.ts,.vue ./ --fix

C:\Users\abashir\Documents\Development\test\src\quasar.d.ts
  5:1  error  This line has a length of 101. Maximum allowed is 100  max-len

✖ 1 problem (1 error, 0 warnings)

error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

 yarn install FAILED... Possible temporary npm registry issues?
 Please try again later...
/*
 * This file runs in a Node context (it's NOT transpiled by Babel), so use only
 * the ES6 features that are supported by your Node version. https://node.green/
 */

// Configuration for your app
// https://v2.quasar.dev/quasar-cli/quasar-conf-js

/* eslint-env node */
/* eslint-disable @typescript-eslint/no-var-requires */
/* eslint func-names: 0 */
/* eslint global-require: 0 */
const { configure } = require('quasar/wrappers');

module.exports = configure((ctx) => ({
  // https://v2.quasar.dev/quasar-cli/supporting-ts
  supportTS: {
    tsCheckerConfig: {
      eslint: {
        enabled: true,
        files: './src/**/*.{ts,tsx,js,jsx,vue}',
      },
    },
  },

  // https://v2.quasar.dev/quasar-cli/prefetch-feature
  // preFetch: true,

  // app boot file (/src/boot)
  // --> boot files are part of "main.js"
  // https://v2.quasar.dev/quasar-cli/boot-files
  boot: [
    'axios',
  ],

  // https://v2.quasar.dev/quasar-cli/quasar-conf-js#Property%3A-css
  css: [
    'app.scss',
  ],

  // https://github.com/quasarframework/quasar/tree/dev/extras
  extras: [
    // 'ionicons-v4',
    // 'mdi-v5',
     'fontawesome-v5',
    // 'eva-icons',
    // 'themify',
    // 'line-awesome',
    // 'roboto-font-latin-ext', // this or either 'roboto-font', NEVER both!

    'roboto-font', // optional, you are not bound to it
    'material-icons', // optional, you are not bound to it
  ],

  // Full list of options: https://v2.quasar.dev/quasar-cli/quasar-conf-js#Property%3A-build
  build: {
    vueRouterMode: 'history', // available values: 'hash', 'history'

    // transpile: false,

    // Add dependencies for transpiling with Babel (Array of string/regex)
    // (from node_modules, which are by default not transpiled).
    // Applies only if "transpile" is set to true.
    // transpileDependencies: [],

    // rtl: true, // https://v2.quasar.dev/options/rtl-support
    // preloadChunks: true,
    // showProgress: false,
    // gzip: true,
    // analyze: true,

    // Options below are automatically set depending on the env, set them if you want to override
    // extractCSS: false,

    // https://v2.quasar.dev/quasar-cli/handling-webpack
    // "chain" is a webpack-chain object https://github.com/neutrinojs/webpack-chain
    chainWebpack(/* chain */) {
      //
    },
  },

  // Full list of options: https://v2.quasar.dev/quasar-cli/quasar-conf-js#Property%3A-devServer
  devServer: {
    https: false,
    port: 8080,
    open: true, // opens browser window automatically
  },

  // https://v2.quasar.dev/quasar-cli/quasar-conf-js#Property%3A-framework
  framework: {
    config: {},

    // iconSet: 'material-icons', // Quasar icon set
    // lang: 'en-US', // Quasar language pack

    // For special cases outside of where the auto-import strategy can have an impact
    // (like functional components as one of the examples),
    // you can manually specify Quasar components/directives to be available everywhere:
    //
    // components: [],
    // directives: [],

    // Quasar plugins
    plugins: [],
  },

  // animations: 'all', // --- includes all animations
  // https://v2.quasar.dev/options/animations
  animations: [],

  // https://v2.quasar.dev/quasar-cli/developing-ssr/configuring-ssr
  ssr: {
    pwa: false,

    // manualStoreHydration: true,
    // manualPostHydrationTrigger: true,

    prodPort: 3000, // The default port that the production server should use
    // (gets superseded if process.env.PORT is specified at runtime)

    maxAge: 1000 * 60 * 60 * 24 * 30,
    // Tell browser when a file from the server should expire from cache (in ms)

    chainWebpackWebserver(/* chain */) {
      //
    },

    middlewares: [
      ctx.prod ? 'compression' : '',
      'render', // keep this as last one
    ],
  },

  // https://v2.quasar.dev/quasar-cli/developing-pwa/configuring-pwa
  pwa: {
    workboxPluginMode: 'GenerateSW', // 'GenerateSW' or 'InjectManifest'
    workboxOptions: {}, // only for GenerateSW

    // for the custom service worker ONLY (/src-pwa/custom-service-worker.[js|ts])
    // if using workbox in InjectManifest mode
    chainWebpackCustomSW(/* chain */) {
      //
    },

    manifest: {
      name: 'Tehqeeq',
      short_name: 'Tehqeeq',
      description: 'A Quasar Framework app',
      display: 'standalone',
      orientation: 'portrait',
      background_color: '#ffffff',
      theme_color: '#027be3',
      icons: [
        {
          src: 'icons/icon-128x128.png',
          sizes: '128x128',
          type: 'image/png',
        },
        {
          src: 'icons/icon-192x192.png',
          sizes: '192x192',
          type: 'image/png',
        },
        {
          src: 'icons/icon-256x256.png',
          sizes: '256x256',
          type: 'image/png',
        },
        {
          src: 'icons/icon-384x384.png',
          sizes: '384x384',
          type: 'image/png',
        },
        {
          src: 'icons/icon-512x512.png',
          sizes: '512x512',
          type: 'image/png',
        },
      ],
    },
  },

  // Full list of options: https://v2.quasar.dev/quasar-cli/developing-cordova-apps/configuring-cordova
  cordova: {
    // noIosLegacyBuildFlag: true, // uncomment only if you know what you are doing
  },

  // Full list of options: https://v2.quasar.dev/quasar-cli/developing-capacitor-apps/configuring-capacitor
  capacitor: {
    hideSplashscreen: true,
  },

  // Full list of options: https://v2.quasar.dev/quasar-cli/developing-electron-apps/configuring-electron
  electron: {
    bundler: 'packager', // 'packager' or 'builder'

    packager: {
      // https://github.com/electron-userland/electron-packager/blob/master/docs/api.md#options

      // OS X / Mac App Store
      // appBundleId: '',
      // appCategoryType: '',
      // osxSign: '',
      // protocol: 'myapp://path',

      // Windows only
      // win32metadata: { ... }
    },

    builder: {
      // https://www.electron.build/configuration/configuration

      appId: 'tehqeeq',
    },

    // "chain" is a webpack-chain object https://github.com/neutrinojs/webpack-chain
    chainWebpack(/* chain */) {
      // do something with the Electron main process Webpack cfg
      // extendWebpackMain also available besides this chainWebpackMain
    },

    // "chain" is a webpack-chain object https://github.com/neutrinojs/webpack-chain
    chainWebpackPreload(/* chain */) {
      // do something with the Electron main process Webpack cfg
      // extendWebpackPreload also available besides this chainWebpackPreload
    },
  },
}));

@IlCallo
Copy link
Member

IlCallo commented Oct 12, 2021

You use eslint 8, fork-ts-checker (used behind the curtains to manage TS checking) isn't compatible with that yet: TypeStrong/fork-ts-checker-webpack-plugin#664

@afnan
Copy link
Author

afnan commented Oct 12, 2021

You use eslint 8, fork-ts-checker (used behind the curtains to manage TS checking) isn't compatible with that yet: TypeStrong/fork-ts-checker-webpack-plugin#664

Since it does not affect the working, its just wait and see till it becomes compatible?

@IlCallo
Copy link
Member

IlCallo commented Oct 13, 2021

Possibly? Even if I won't bet on that, fork-ts-checker will remove ESLint support into the next major release so he possibly isn't willing to support ESLint 8 at all, but the maintainer is the one you should really ask to

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Qv2 🔝 Quasar v2 issues
Projects
None yet
Development

No branches or pull requests

3 participants