Code Monkey home page Code Monkey logo

Comments (4)

javierbrea avatar javierbrea commented on June 2, 2024 1

Hi @Magg1808 ,
Thanks for the notice, this is the right place for this type of questions, of course 😉 . The plugin tests are checking the TypeScript declarations, but they don't include Cypress 11 for the moment, so it is probably related to Cypress version. I will add Cypress 11 and 12 to the test batteries as soon as possible.

from cypress-fail-fast.

javierbrea avatar javierbrea commented on June 2, 2024 1

Hello again,

thanks for reply. Could the problem of using import instead of require to download this tool also be related to the Cypress version? When I use the syntax import cypressFailFast from 'cypress-fail-fast/plugin'; or import { cypressFailFast } from 'cypress-fail-fast/plugin'; in the cypress.config.ts file and then
...

No, that seems related to the way you are importing the plugin. Note that in TypeScript the plugin has to be imported using import cypressFailFast = require("cypress-fail-fast/plugin");, as described in the documentation.

from cypress-fail-fast.

Magg1808 avatar Magg1808 commented on June 2, 2024

Hello again,

thanks for reply. Could the problem of using import instead of require to download this tool also be related to the Cypress version?
When I use the syntax import cypressFailFast from 'cypress-fail-fast/plugin'; or import { cypressFailFast } from 'cypress-fail-fast/plugin'; in the cypress.config.ts file
and then

setupNodeEvents(on, config) {
      cypressFailFast(on, config);
      return config;
      }

I get this error:
1 2

Maybe I converted it wrong?

With this syntax it works fine:

setupNodeEvents(on, config) {
 // eslint-disable-next-line @typescript-eslint/no-var-requires, unicorn/prefer-module
require('cypress-fail-fast/plugin')(on, config);
 return config;
}

from cypress-fail-fast.

javierbrea avatar javierbrea commented on June 2, 2024

The issue has been fixed on release v6.0.0

from cypress-fail-fast.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.