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.

Sourcemaps for the cli

See original GitHub issue

The cli does run sourceMapSupport.install() but I suspect it’s not working as expected with babel etc. The cli and its webpack config was the very first thing I started when I started this project so it’s most likely rough and hacky.

The problem comes from the fact that unexpected errors produce near useless stack traces.

Try…

  1. Edit something like client/src/document.js and put in a throw new Error('hello world') somewhere in some component.
  2. Run cd cli && CLI_BUILD_HTML=true yarn run run ../stumptown/packaged/html/reference/elements/video.json

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:7 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
peterbecommented, Mar 1, 2022

Hey @peterbe 😄 Have been enjoying looking through this repo - out of curiosity, was there a limitation on Next.js that prevented y’all from adopting it and doing hand-rolled React SSR?

Initially, it was lack of skills. In my defense, the early prototype of Yari was made when NextJS wasn’t even known 😃 At the time I was very comfortable around CRA and just wanted to get something up and running. By the time we realized what a mess CRA is when you want to do SSR and having to do your own Babel etc. so you can use it in Node, it was clear that we needed something like NextJS. From there, we just didn’t get around to it. Like a recurring piece of tech debt we rolled along in front of us.

We did attempt some NextJS at one point, led by my colleague, but in hindsight, I think that project attempted to do EVERYTHING the NextJS way including running it in Vercel. It would have been better to allow the regular Node code entirely worry itself with doing the Markdown and macro expansion stuff and dumping to the file system (or a database). Then, the getStaticProps (or getServerSideProps) could just read the content from disk, by taking the req.path and transposing it to the relevant build/${path}.json kinda deal. That way, we’d get NextJS to handle all SSR but become agnostic as to how the hell the HTML payload is prepared.

I left the Yari (Mozilla) in late 2021 and I used NextJS on my personal and new work projects.

0reactions
leerobcommented, Mar 1, 2022

Hey @peterbe 😄 Have been enjoying looking through this repo - out of curiosity, was there a limitation on Next.js that prevented y’all from adopting it and doing hand-rolled React SSR?

Read more comments on GitHub >

github_iconTop Results From Across the Web

source-map-cli - npm
The resolve command accepts a source map (either a path or a URL), a line and column and returns the original source file...
Read more >
gabmontes/source-map-cli - GitHub
The resolve command accepts a source map (either a path or a URL), a line and column and returns the original source file...
Read more >
Upload source maps from the CLI - elmah.io
Upload a source map from the CLI. The sourcemap command is used to upload source maps and minified JavaScript files to elmah.io.
Read more >
Sentry CLI for JavaScript
Sentry uses releases to match the correct uploaded source maps to your events. You can use sentry-cli to create releases and upload source...
Read more >
source-map-url-cli | Yarn - Package Manager
unpkg: unpkg.com/source-map-url-cli/. jsDelivr: cdn.jsdelivr.net/npm/source-map-url-cli/. bundle.run: bundle.run/source-map-url-cli ...
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