[components/MdxContent][s]: reverted dyn import
This commit is contained in:
parent
1ae7095d69
commit
5524c73614
|
|
@ -1,11 +1,21 @@
|
||||||
import React from "react";
|
import React from "react";
|
||||||
import Head from "next/head";
|
import Head from "next/head";
|
||||||
|
import dynamic from "next/dynamic";
|
||||||
import { useMDXComponent } from "next-contentlayer/hooks";
|
import { useMDXComponent } from "next-contentlayer/hooks";
|
||||||
|
|
||||||
import useHeadingsObserver from "../hooks/useHeadingsObserver";
|
|
||||||
import { Paragraph } from "./Paragraph";
|
|
||||||
import { Anchor } from "./Anchor";
|
|
||||||
import { Heading } from "./Heading";
|
import { Heading } from "./Heading";
|
||||||
|
import useHeadingsObserver from "../hooks/useHeadingsObserver";
|
||||||
|
|
||||||
|
const Anchor = dynamic(
|
||||||
|
() => import("./Anchor").then((module) => module.Anchor)
|
||||||
|
// {
|
||||||
|
// ssr: false,
|
||||||
|
// }
|
||||||
|
);
|
||||||
|
|
||||||
|
const Paragraph = dynamic(() =>
|
||||||
|
import("./Paragraph").then((module) => module.Paragraph)
|
||||||
|
);
|
||||||
|
|
||||||
const MdxContent = ({ body }) => {
|
const MdxContent = ({ body }) => {
|
||||||
const observer = useHeadingsObserver();
|
const observer = useHeadingsObserver();
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue