You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The primary docs site is replete with issues related to the use of Chai, specifically in terms of the differences between Chai 4 and Chai 5.
For example, there are still plenty of places that read that one should use:
import chai from 'chai';
when the Chai 5 ESM-only version doesn't have a default exported object, so that fails. It took me a while to figure out that everything is now a named export, so if I want to use a plugin, I have to use:
import { use, expect } from 'chai';
and then change all my chai.use() calls to just use that newly-exported use method.
Is there a Chai 5/ESM-only doc page that helps folks make these changes?
The text was updated successfully, but these errors were encountered:
The primary docs site is replete with issues related to the use of Chai, specifically in terms of the differences between Chai 4 and Chai 5.
For example, there are still plenty of places that read that one should use:
when the Chai 5 ESM-only version doesn't have a default exported object, so that fails. It took me a while to figure out that everything is now a named export, so if I want to use a plugin, I have to use:
and then change all my
chai.use()
calls to just use that newly-exporteduse
method.Is there a Chai 5/ESM-only doc page that helps folks make these changes?
The text was updated successfully, but these errors were encountered: