-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Update docs for Cypress.require() #5020
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a reminder for us whenever we create the 12.6
docs branch to base this PR off of it to merge
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@chrisbreiding It might be nice to have a 'why' explaining why this is necessary somewhere in the Cypress.require doc, in a notes section? I think my immediate thoughts if I were to read this for the first time would be....why?? why do I have to do this?? There's no context given, we just tell them they have to.
Addressed in b98b945. |
@chrisbreiding Thanks, the 'why' section is nice context. Will leave it to other to fully review the content. |
cy.origin('somesite.com', () => { | ||
const _ = require('lodash') | ||
const utils = require('../support/utils') | ||
const _ = Cypress.require('lodash') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
one can still use Cypress._
here if they wanted to right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, they can
For cypress-io/cypress#25626