Giter VIP home page Giter VIP logo

Comments (8)

moooji avatar moooji commented on June 4, 2024 1

@kylehotchkiss I think your solution was actually pretty close. I just did a npm i babel-runtime --save in the functions folder (not the app) and it seems to work so far.

from firebase-functions-next-example.

gulukul avatar gulukul commented on June 4, 2024 1

@jthegedus I am facing similar problems. Please post your solution :)

Thank you.

from firebase-functions-next-example.

jthegedus avatar jthegedus commented on June 4, 2024 1

@gulukul The new code is live on this repo, give it a read to see the changes before running. It should solve this particular problem (and some other issues).

@flexlee I'm writing it atm, should be published before this coming weekend. It'll explain everything from scratch (not assuming any knowledge of the prior implementation).

Sorry for the delay but I've spread myself too thin and haven't been able to get around to everything. I'm starting to get on top of everything. Triaging my repos and getting these associated blog posts out is priority 1. Thanks for your patience.

from firebase-functions-next-example.

jthegedus avatar jthegedus commented on June 4, 2024

The reason I went with this file structure is that I too had problems using Babel. Next.js searches for Babel files higher in the path and uses those if found which causes problems with its own internal Babel settings. Where were you putting the Babel file and where were you using the spread operator?

from firebase-functions-next-example.

moooji avatar moooji commented on June 4, 2024

I have a very similar issue. I changed the sample to use React classes like this in pages/index.js

import React from "react";
import Header from "../components/Header";

class Index extends React.Component {
  render() {
    return (
      <div>
        <Header />
        <p>Hello</p>
      </div>
    );
  }
}

export default Index;

This leads to a 500 and a similar Babel issue in the logs: Cannot find module 'babel-runtime/core-js/object/get-prototype-of'

from firebase-functions-next-example.

jthegedus avatar jthegedus commented on June 4, 2024

Hey all, I've got a new solution coming out over the weekend that should solve this problem, it's a much simpler setup. Thanks for taking the time to post and sharing your solutions 😄

from firebase-functions-next-example.

flexlee avatar flexlee commented on June 4, 2024

@jthegedus Thanks for the solution. Is your post coming out soon?

from firebase-functions-next-example.

jthegedus avatar jthegedus commented on June 4, 2024

I'll consider this closed since this is no longer a problem with the new repo example. I'm still working on the new Medium post which I will link here when finished (or you can follow me on Medium to get real-time updates.

from firebase-functions-next-example.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.