-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Bump packages and upgrade to next14 (#512)
* bumps to next14 * bump packages * bump packages * bump packages * bump packages * bump packages * fixes tests * fixes build warnings
- Loading branch information
Showing
19 changed files
with
3,194 additions
and
2,405 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
module.exports = "MDX CONTENT" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
// import { createTransformer } from 'babel-jest'; | ||
import { compileSync } from '@mdx-js/mdx'; | ||
import { transformSync } from "@babel/core"; | ||
// import {inspect} from "util" | ||
// import path from 'path'; | ||
|
||
// import {require} from 'module' | ||
|
||
export default { | ||
process(sourceText, sourcePath, options) { | ||
// console.log("HELLO") | ||
const code = compileSync(sourceText, { | ||
recmaPlugins: [() => ({ Compiler: import('estree-to-babel') })], | ||
}); | ||
|
||
const result = transformSync(code.value, { | ||
presets: [['@babel/preset-env', { modules: 'cjs' }]], | ||
plugins: ['add-module-exports'] | ||
}) | ||
|
||
// console.log(result) | ||
|
||
return result | ||
|
||
|
||
// console.log(inspect(result, false, null)); | ||
// return { | ||
// code: `module.exports = ${JSON.stringify(path.basename(sourcePath))};`, | ||
// }; | ||
}, | ||
|
||
async processAsync(sourceText, sourcePath) { | ||
const code = await compile(sourceText, { | ||
recmaPlugins: [() => ({ Compiler: import('estree-to-babel') })], | ||
}); | ||
|
||
const result = await transform(code.value, { | ||
presets: [['@babel/preset-env', { modules: 'commonjs' }]], | ||
plugins: ['add-module-exports'] | ||
}) | ||
|
||
return result | ||
} | ||
}; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
f34b3d3
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
me.kochie.io – ./
mekochieio-git-main-kochie1.vercel.app
mekochieio-kochie1.vercel.app
me.kochie.io
robertkoch.me