You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am using the following to access my package.json info for ESM projects:
import{createRequire}from"module";constrequire=createRequire(import.meta.url);constpackageJson=require("./package.json");// <--- change the path to your packege.json accordingly
there is no require or
module
(afaik) in ESM, so is there a way to get pkginfo in ESM Node?The text was updated successfully, but these errors were encountered: