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
I've custom higher level amp safe components that behave differently on amp / react version of app.
The problems is that for testing those components I've to import AmpStateContext from next/dist/next-server/lib/amp-context.
Describe the solution you'd like
I like to import it from next/amp or next/amp-context. though it should be documented that's for testing purpose.
Describe alternatives you've considered
importing AmpStateContext from next/dist/next-server/lib/amp-context. Mocking can be an option too.
This discussion was converted from issue #14090 on April 12, 2021 11:52.
Heading
Bold
Italic
Quote
Code
Link
Numbered list
Unordered list
Task list
Attach files
Mention
Reference
Menu
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Feature request
I've custom higher level amp safe components that behave differently on amp / react version of app.
The problems is that for testing those components I've to import AmpStateContext from
next/dist/next-server/lib/amp-context
.Describe the solution you'd like
I like to import it from
next/amp
ornext/amp-context
. though it should be documented that's for testing purpose.Describe alternatives you've considered
importing AmpStateContext from
next/dist/next-server/lib/amp-context
. Mocking can be an option too.Beta Was this translation helpful? Give feedback.
All reactions