question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

SPA app with backend (server.js)

See original GitHub issue

❓Question

Hi and thank you for creating Razzle! 🎉

I’m looking for a zero-configuration tool for SPA applications including the backend, and I’m not sure if Razzle is the correct tool for this.

I already started building the app using with-typescript example, added some API endpoints to server.tsx, but now I want to remove the server-side rending part.

However, as the guide says - https://razzlejs.org/docs/single-page-applications - that’d mean also removing server.js, but that already contains my endpoints.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:32

github_iconTop GitHub Comments

1reaction
fivethreeocommented, Nov 27, 2021

resolved 😃

0reactions
akoskmcommented, Nov 27, 2021

If you remove performacnce?

Exactly, if remove performance this error appears.

i mean for web only

If you meant by this, what if I leave it for web only, that also makes the problem disappear. But I think that’s OK because this is a problem for the web assets in the first place.

    if (!dev && target === 'web') {
      webpackConfig.performance = Object.assign(
        {},
        {
          maxAssetSize: 100000,
          maxEntrypointSize: 300000,
          hints: false,
        }
      );
    }

with this the build is also ✅

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to Build an SPA with React and Node.js | by Aakash Jha
Run a Node server backend for your React project - No more fights between UI and Server. React is no doubt an awesome...
Read more >
Node.js API Implementation (SPAs + API) - Auth0
The Node.js implementation of the API for the SPA + API architecture scenario. ... authenticate HTTP requests using JWT tokens in your Node.js...
Read more >
Comparison of Proxing To Backend Server in SPA Frameworks
Once you install all the dependencies, you can start both Angular app and node js server on 4200 and 3070 respectively.
Read more >
Developing A Single Page Application With Node.js
The development of SPAs is possible through Javascript frameworks ( React JS., Vue JS., Meteor JS., Angular JS.); Node.js backend platform, or ...
Read more >
Building a secure single-page application (SPA) with React.js
js, React Router, and axios. The backend application is built with Node.js, Express.js, and MongoDB and is the result of a project discussed...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found