mirror of
https://github.com/cypress-io/cypress.git
synced 2026-05-25 01:49:06 -05:00
fix: add React.Suspense boundary to lazy-loaded App and remove stray eslint-env comment
This commit is contained in:
@@ -5,7 +5,9 @@ const OtherComponent = React.lazy(() => import('./OtherComponent'))
|
||||
export default function App () {
|
||||
return (
|
||||
<div className="app">
|
||||
<OtherComponent />
|
||||
<React.Suspense fallback={'loading...'}>
|
||||
<OtherComponent />
|
||||
</React.Suspense>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
@@ -2,7 +2,6 @@ import { HelloX } from './hello-x.jsx'
|
||||
import React from 'react'
|
||||
import { mount } from '@cypress/react'
|
||||
|
||||
/* eslint-env mocha */
|
||||
describe('HelloX component', () => {
|
||||
it('works', () => {
|
||||
mount(<HelloX name="SuperMan" />)
|
||||
|
||||
Reference in New Issue
Block a user