Skip to content

Question/Feature request: Is there a way to run msw independently from the frontend app? #1040

Answered by kettanaito
flowck asked this question in Q&A
Discussion options

You must be logged in to vote

Hey, @flowck. Thanks for raising this.

It'd be great to improve the recipe to rely on patterns you can use in any framework/setup, no matter how abstracted. Like with NextJS, where you don't control the application mounting directly.

I am thinking: why going into this trouble when I can have the mock server completely detached from the frontend app?

Devising this deferred rendering pattern may seem like a chore but it's insignificant compared to the cost of writing and running a standalone server, even if for the local development. On top of that, there are other things that a mocked server implies, such as routing all your requests to that server just for the sake of development/testin…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by kettanaito
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #1039 on December 28, 2021 01:34.