diff --git a/packages/gatsby-core-utils/src/get-gatsby-version.js b/packages/gatsby-core-utils/src/get-gatsby-version.ts similarity index 72% rename from packages/gatsby-core-utils/src/get-gatsby-version.js rename to packages/gatsby-core-utils/src/get-gatsby-version.ts index f9d4097f3fd6a..ec32804a9467a 100644 --- a/packages/gatsby-core-utils/src/get-gatsby-version.js +++ b/packages/gatsby-core-utils/src/get-gatsby-version.ts @@ -1,6 +1,6 @@ import path from "path" -module.exports = () => { +const getGatsbyVersion = (): string => { try { return require(path.join( process.cwd(), @@ -12,3 +12,5 @@ module.exports = () => { return `` } } + +export default getGatsbyVersion