Coder Social home page Coder Social logo

Comments (6)

wolfy1339 avatar wolfy1339 commented on July 3, 2024 2

You don't need @octokit/core when using @actions/github

@actions/github requires v5 @octokit/core, which breaks newer @octokit/core versions defined as dependencies

from core.js.

wolfy1339 avatar wolfy1339 commented on July 3, 2024 1

Also, I recommend using esbuild instead of ncc as it creates more readable output files, and correctly ouputs ESM, and is much simpler. (From octokit/graphql-action#255 (comment))

Use https://github.com/actions/create-github-app-token/ as a reference

from core.js.

wolfy1339 avatar wolfy1339 commented on July 3, 2024 1

In v6 of @octokit/core we switched to ESM, in v5 we were outputting CJS.

Since you are using plugins, you will have to stick with @octokit/core v5 until @probot/octokit-plugin-config is updated and remove @actions/github

from core.js.

gr2m avatar gr2m commented on July 3, 2024 1

Also, I recommend using esbuild instead of ncc as it creates more readable output files, and correctly ouputs ESM, and is much simpler. (From octokit/graphql-action#255 (comment))

I second that. Use esbuild. I used ncc in the past but esbuild is the better tool to bundle code for actions if your source is ESM

from core.js.

github-actions avatar github-actions commented on July 3, 2024

👋 Hi! Thank you for this contribution! Just to let you know, our GitHub SDK team does a round of issue and PR reviews twice a week, every Monday and Friday! We have a process in place for prioritizing and responding to your input. Because you are a part of this community please feel free to comment, add to, or pick up any issues/PRs that are labled with Status: Up for grabs. You & others like you are the reason all of this works! So thank you & happy coding! 🚀

from core.js.

jamacku avatar jamacku commented on July 3, 2024

@wolfy1339 Thank you for your help! I have removed @octokit/core, and it works as expected.

I'm just a bit confused as to why I'm able to import { Octokit } from '@octokit/core'; without an error.

https://github.com/redhat-plumbers-in-action/regression-sniffer/blob/main/src/octokit.ts#L2

Thank you for suggesting esbuild. I'll have a look.

from core.js.

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.