<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/">
    <channel>
        <title>NotionNext帮助手册</title>
        <link>https://docs.tangly1024.com/</link>
        <description>Notion开源、免费、快速建站</description>
        <lastBuildDate>Mon, 06 Apr 2026 04:50:50 GMT</lastBuildDate>
        <docs>https://validator.w3.org/feed/docs/rss2.html</docs>
        <generator>https://github.com/jpmonette/feed</generator>
        <language>en-US</language>
        <copyright>All rights reserved 2026, NotionNext</copyright>
        <item>
            <title><![CDATA[V4.9.4.2]]></title>
            <link>https://docs.tangly1024.com/article/latest</link>
            <guid>https://docs.tangly1024.com/article/latest</guid>
            <pubDate>Sat, 11 Oct 2025 00:00:00 GMT</pubDate>
            <content:encoded><![CDATA[<div id="notion-article" class="mx-auto overflow-hidden "><main class="notion light-mode notion-page notion-block-289f93b9208b803d98bed48891b882db"><div class="notion-viewport"></div><div class="notion-collection-page-properties"></div><div class="notion-callout notion-orange_background_co notion-block-301f93b9208b80928193c590e928dd39"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text"><div class="notion-text notion-block-301f93b9208b80e9bf5edf9b3cbf6db4">由于Notion数据格式的变化，所有在 2026.4.2 之前部署的站点请升级至最新版本。
可以关注此页面，或项目讨论页获取最新动态：

<a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://docs.tangly1024.com/article/latest">https://docs.tangly1024.com/article/latest</a></div><div class="notion-text notion-block-302f93b9208b80dfb48ac1b1ab588dcd"><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/issues">https://github.com/tangly1024/NotionNext/issues</a></div></div></div><div class="notion-callout notion-gray_background_co notion-block-301f93b9208b80e6a369f49702efa98b"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text"><div class="notion-text notion-block-301f93b9208b8086b138ff7a4b2fe5d2">最新事件：2026.4.2 Notion再次更新了接口的数据格式，导致旧版站点不可用。NotionNext紧急发布4.9.3.2 版本修复。4.9.3.2伴随部分数据获取的bug，在4.9.4.2版本中修复。</div><details class="notion-toggle notion-block-336f93b9208b809c933cef8497d0b59d"><summary>过往事件  2026.2.7</summary><div><div class="notion-text notion-block-336f93b9208b809ca4e2e8eef7d40226">2026.2.7，Notion官方调整了数据结构，导致旧版NotionNext数据异常，目前已恢复，Notion突然的升级，让我又掉了不少头发。
相关问题讨论：<a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/issues/3749">https://github.com/tangly1024/NotionNext/issues/3749</a></div></div></details><details class="notion-toggle notion-block-301f93b9208b807496b7e7d0ff2b3822"><summary>过往事件　2025.10.8</summary><div><div class="notion-callout notion-orange_background_co notion-block-289f93b9208b808a87b7f96f110cffd9"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text"><div class="notion-text notion-block-289f93b9208b8037b8dcc6bc17900271">由于NotionAPI的升级，建议所有在2025.10.11之前部署的站点都升级至4.9.2的最新版</div></div></div><div class="notion-text notion-block-301f93b9208b803eb771e2c42463057b">事件：2025.10.08 ,  Notion官方api改动，导致所有旧版本的NotionNext站点无法部署。站长反馈站点出现大量的530API异常。</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-289f93b9208b80a2a5f0f4d5d5e41707"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:576px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/attachment%3A2e73f0a0-d23f-4868-9309-333910f67e75%3Aimage.png?table=block&amp;id=289f93b9-208b-80a2-a5f0-f4d5d5e41707&amp;t=289f93b9-208b-80a2-a5f0-f4d5d5e41707" alt="notion image" loading="lazy" decoding="async"/></div></figure></div></details></div></div><div class="notion-blank notion-block-339f93b9208b80a49164cbbb056c1c53"> </div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-336f93b9208b80d0a047c60c1bdf7c7b" data-id="336f93b9208b80d0a047c60c1bdf7c7b"><span><div id="336f93b9208b80d0a047c60c1bdf7c7b" class="notion-header-anchor"></div><a class="notion-hash-link" href="#336f93b9208b80d0a047c60c1bdf7c7b" title="V4.9.4.2 2026.4.5"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">V4.9.4.2 2026.4.5</span></span></h2><ul class="notion-list notion-list-disc notion-block-339f93b9208b8051ae35d718e99885d1"><li>针对 4.9.3.2 - 4.9.4 版本中，为了兼容Notion数据格式变动，而产生的新bug进行修复；</li></ul><ul class="notion-list notion-list-disc notion-block-339f93b9208b80aeaabec2941659830c"><li>修复 由于循环获取数据，导致API超频调用 Too Many Requests 429的问题，同时导致部分文章数据丢失的问题。</li></ul><ul class="notion-list notion-list-disc notion-block-33af93b9208b80d29f18cb877b9adc02"><li>构建模式调整</li><ul class="notion-list notion-list-disc notion-block-33af93b9208b80d29f18cb877b9adc02"><ol start="1" class="notion-list notion-list-numbered notion-block-33af93b9208b80b48aa3d78e6399a01d" style="list-style-type:decimal"><li>默认改为 ISR（fallback: &#x27;blocking&#x27;），并且最多预存首页文章与最新文章（不超过10篇），控制编译打包时长。</li></ol><ol start="2" class="notion-list notion-list-numbered notion-block-33af93b9208b8001a3aae84ed1647f7f" style="list-style-type:decimal"><li>仅纯静态部署方案使用全量SSG。</li></ol></ul></ul><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-336f93b9208b802f870ed329fd00b5d6" data-id="336f93b9208b802f870ed329fd00b5d6"><span><div id="336f93b9208b802f870ed329fd00b5d6" class="notion-header-anchor"></div><a class="notion-hash-link" href="#336f93b9208b802f870ed329fd00b5d6" title="V4.9.4 2026.4.2"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">V4.9.4 2026.4.2</span></span></h2><ul class="notion-list notion-list-disc notion-block-336f93b9208b809ca9b1c6189805ec98"><li>将 react-notion-x/notion-utils 组件升级至 7.10.0 版本，修复页面部分样式丢失的问题</li></ul><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-336f93b9208b80ffbafaeaf358535f25" data-id="336f93b9208b80ffbafaeaf358535f25"><span><div id="336f93b9208b80ffbafaeaf358535f25" class="notion-header-anchor"></div><a class="notion-hash-link" href="#336f93b9208b80ffbafaeaf358535f25" title="V4.9.3.2 2026.4.2"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title"><b>V4.9.3.2 2026.4.2</b></span></span></h2><div class="notion-text notion-block-339f93b9208b801780cbe135cc93a917"><b>What&#x27;s Changed</b></div><ul class="notion-list notion-list-disc notion-block-336f93b9208b80429b98d98f4fa08d99"><li>hotfix： 兼容NOTION_API升级 by <b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024">@tangly1024</a></b> in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3746">#3746</a></li></ul><ul class="notion-list notion-list-disc notion-block-336f93b9208b8092a8bddde77be23b81"><li>修复由于Notion数据格式改变导致的编译异常 by <b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tanglyqq">@tanglyqq</a></b> in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3883">#3883</a> <b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024">@tangly1024</a></b> in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3884">#3884</a></li></ul><ul class="notion-list notion-list-disc notion-block-336f93b9208b807e80ebde8ff23c51cc"><li>log by <b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024">@tangly1024</a></b> in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3747">#3747</a></li></ul><ul class="notion-list notion-list-disc notion-block-336f93b9208b8086bf3fc1450474b9b6"><li>保证编译通过 by <b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024">@tangly1024</a></b> in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3748">#3748</a></li></ul><ul class="notion-list notion-list-disc notion-block-336f93b9208b8036b198d4b66c0047d8"><li>Release/4.9.2.1 by <b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024">@tangly1024</a></b> in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3752">#3752</a></li></ul><ul class="notion-list notion-list-disc notion-block-336f93b9208b800d99f9e40a0037859e"><li>修復clerk 無法編譯 by <b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024">@tangly1024</a></b> in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3753">#3753</a></li></ul><ul class="notion-list notion-list-disc notion-block-336f93b9208b8074a6a3f1e46d7abe63"><li>Release/4.9.3 by <b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024">@tangly1024</a></b> in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3757">#3757</a></li></ul><ul class="notion-list notion-list-disc notion-block-336f93b9208b809db1d1f28613575967"><li>页面url转换bug by <b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024">@tangly1024</a></b> in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3771">#3771</a></li></ul><ul class="notion-list notion-list-disc notion-block-336f93b9208b80b0b09bfe5d0531c84b"><li>文章路由错乱bug by <b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024">@tangly1024</a></b> in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3802">#3802</a></li></ul><ul class="notion-list notion-list-disc notion-block-336f93b9208b80528b03f712ba2089fc"><li>英雄区副文章数量 by <b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tanglyqq">@tanglyqq</a></b> in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3870">#3870</a></li></ul><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-336f93b9208b80899d32ca99220363ed"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:20px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://avatars.githubusercontent.com/u/15920488?s=40&amp;v=4&amp;spaceId=6c096b44-beb9-48ee-8f92-1efdde47f3a3&amp;t=336f93b9-208b-8089-9d32-ca99220363ed" alt="@tangly1024" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-336f93b9208b8061bb7ce75a6ee5c719"><b>Full Changelog</b>: <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/compare/v4.9.3...v4.9.3.2">v4.9.3...v4.9.3.2</a></div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-301f93b9208b8037871bcc339b7e20ec" data-id="301f93b9208b8037871bcc339b7e20ec"><span><div id="301f93b9208b8037871bcc339b7e20ec" class="notion-header-anchor"></div><a class="notion-hash-link" href="#301f93b9208b8037871bcc339b7e20ec" title="V4.9.3 2026.2.8"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title"><b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/releases/tag/v4.9.3">V4.9.3</a></b><b> 2026.2.8</b></span></span></h2><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-301f93b9208b8075a869e7e23a1b678a"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:20px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://avatars.githubusercontent.com/u/15920488?s=40&amp;v=4&amp;spaceId=6c096b44-beb9-48ee-8f92-1efdde47f3a3&amp;t=301f93b9-208b-8075-a869-e7e23a1b678a" alt="@tangly1024" loading="lazy" decoding="async"/></div></figure><ul class="notion-list notion-list-disc notion-block-301f93b9208b80acaf03eb72bf361480"><li>修复Notion数据更新导致的站点部署异常，数据显示异常等bug</li></ul><ul class="notion-list notion-list-disc notion-block-301f93b9208b805b8206f3038b458c9c"><li>在文章分享区增加了CSDN和稀土掘金的选项 by <b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/DalnyEFZ">@DalnyEFZ</a></b> in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3691">#3691</a></li></ul><ul class="notion-list notion-list-disc notion-block-301f93b9208b8041be27fcf242316191"><li>修复了Next主题无法解密邮件地址 by <b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/KZaqur">@KZaqur</a></b> in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3709">#3709</a></li></ul><div class="notion-text notion-block-301f93b9208b80b5b6e5e7beacd7d5e9"><b>New Contributors</b></div><ul class="notion-list notion-list-disc notion-block-301f93b9208b80219dc5f7452f6497da"><li><b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/DalnyEFZ">@DalnyEFZ</a></b> made their first contribution in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3691">#3691</a></li></ul><ul class="notion-list notion-list-disc notion-block-301f93b9208b80a79ac3fbbf178138c1"><li><b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/KZaqur">@KZaqur</a></b> made their first contribution in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3709">#3709</a></li></ul><div class="notion-text notion-block-301f93b9208b805ead3ff6d16870594d"><b>Full Changelog</b>: <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/compare/v4.9.2...v4.9.3">v4.9.2...v4.9.3</a></div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-289f93b9208b8039a6c8dddddd1a938b" data-id="289f93b9208b8039a6c8dddddd1a938b"><span><div id="289f93b9208b8039a6c8dddddd1a938b" class="notion-header-anchor"></div><a class="notion-hash-link" href="#289f93b9208b8039a6c8dddddd1a938b" title="V4.9.2 "><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title"><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/releases/tag/v4.9.2">V4.9.2</a> </span></span></h2><ul class="notion-list notion-list-disc notion-block-289f93b9208b80078fd2da42bf6dc95c"><li>2025.10.11 : NotionNext跟随 notion-react-x 补丁，发布4.9.2版本，修复notion-api异常，不再需要额外添加<code class="notion-inline-code">api_base_url</code>进行过度。</li></ul><ul class="notion-list notion-list-disc notion-block-289f93b9208b80eca934f37c3e651138"><li>升级notion-react-x 核心依赖，修复notion-api异常 ，并使网页样式更加贴近Notion Release/4.9.2 by @tangly1024 in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3656">https://github.com/tangly1024/NotionNext/pull/3656</a></li></ul><div class="notion-text notion-block-289f93b9208b80a2b016c95bf2ff6e57"><b>Full Changelog</b>: <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/compare/v4.9.1...v4.9.2">https://github.com/tangly1024/NotionNext/compare/v4.9.1...v4.9.2</a></div><div class="notion-blank notion-block-289f93b9208b808fb890c2058d87757c"> </div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-289f93b9208b80339d7af97a18dda3e4" data-id="289f93b9208b80339d7af97a18dda3e4"><span><div id="289f93b9208b80339d7af97a18dda3e4" class="notion-header-anchor"></div><a class="notion-hash-link" href="#289f93b9208b80339d7af97a18dda3e4" title="v4.9.1 "><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title"><b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/releases/tag/v4.9.1">v4.9.1</a></b><b> </b></span></span></h2><ul class="notion-list notion-list-disc notion-block-289f93b9208b807292e1d8b59524daab"><li>2025.10.09 : 发布紧急补丁版本4.9.1，支持用户配置自定义接口域名，暂时让站点能够使用。</li></ul><ul class="notion-list notion-list-disc notion-block-289f93b9208b809b8d63c492007f8e0a"><li>版本 4.9.1，临时用api_base_url方案处理接口异常。 by @tangly1024 in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3637">https://github.com/tangly1024/NotionNext/pull/3637</a></li></ul><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-289f93b9208b809a94b8d440478d8888" data-id="289f93b9208b809a94b8d440478d8888"><span><div id="289f93b9208b809a94b8d440478d8888" class="notion-header-anchor"></div><a class="notion-hash-link" href="#289f93b9208b809a94b8d440478d8888" title="What&#x27;s Changed"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title"><b>What&#x27;s Changed</b></span></span></h3><ul class="notion-list notion-list-disc notion-block-289f93b9208b80769826d9ed4e24721e"><li>fix(PROXIO): add second button support and improve code structure by <b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/qixing-jk">@qixing-jk</a></b> in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3540">#3540</a></li></ul><ul class="notion-list notion-list-disc notion-block-289f93b9208b80aeb5e3ce346c3541c8"><li>fix(giscus): add padding to prevent iframe overflow by <b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/qixing-jk">@qixing-jk</a></b> in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3579">#3579</a></li></ul><ul class="notion-list notion-list-disc notion-block-289f93b9208b80209352e1dc907ef3a2"><li>【更新waline】更新package.json中的waline/client版本 by <b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/lifeafter619">@lifeafter619</a></b> in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3549">#3549</a></li></ul><ul class="notion-list notion-list-disc notion-block-289f93b9208b8091ad28c905f0c66928"><li>fix notion 溢出1000个block不显示 by <b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024">@tangly1024</a></b> in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3582">#3582</a></li></ul><ul class="notion-list notion-list-disc notion-block-289f93b9208b805f9c06cb0a5c83a82d"><li>UMAMI by <b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024">@tangly1024</a></b> in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3583">#3583</a></li></ul><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-289f93b9208b80da92d1d03af8478a1a" data-id="289f93b9208b80da92d1d03af8478a1a"><span><div id="289f93b9208b80da92d1d03af8478a1a" class="notion-header-anchor"></div><a class="notion-hash-link" href="#289f93b9208b80da92d1d03af8478a1a" title="重要"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title"><b>重要</b></span></span></h3><div class="notion-text notion-block-289f93b9208b8077a5cfda893ee6f76a">由于NotionAPI的调整，增加了一些打包限流的补丁功能</div><ul class="notion-list notion-list-disc notion-block-289f93b9208b80eb8569eddb85ba496a"><li>custom_api_base_url by <b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024">@tangly1024</a></b> in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3632">#3632</a></li></ul><ul class="notion-list notion-list-disc notion-block-289f93b9208b803fafb4f3d5773b5b92"><li>Feat/deploy ratelimiter by <b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024">@tangly1024</a></b> in <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/pull/3636">#3636</a></li></ul><div class="notion-text notion-block-289f93b9208b807bb2e3c1996dc19099"><b>Full Changelog</b>: <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/compare/V4.9.0...v4.9.1">V4.9.0...v4.9.1</a></div></main></div>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[CloudFlarePage静态部署]]></title>
            <link>https://docs.tangly1024.com/article/notion-next-cloud-flare</link>
            <guid>https://docs.tangly1024.com/article/notion-next-cloud-flare</guid>
            <pubDate>Mon, 13 Mar 2023 00:00:00 GMT</pubDate>
            <description><![CDATA[cloudflare支持纯静态导出的notionnext，兼容性不那么好，但不失为一种选择。]]></description>
            <content:encoded><![CDATA[<div id="notion-article" class="mx-auto overflow-hidden "><main class="notion light-mode notion-page notion-block-35ace93ecb074cd79b88411303ed98b6"><div class="notion-viewport"></div><div class="notion-collection-page-properties"></div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-7d9dd495a69b4af78641fec9f2e3a702" data-id="7d9dd495a69b4af78641fec9f2e3a702"><span><div id="7d9dd495a69b4af78641fec9f2e3a702" class="notion-header-anchor"></div><a class="notion-hash-link" href="#7d9dd495a69b4af78641fec9f2e3a702" title="前言"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">前言</span></span></h2><div class="notion-callout notion-gray_background_co notion-block-402a5400bef64aa782fdc93ab6a3e17a"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text">CloudFlare方案适用于站点访问量大，而文章更新不频繁的用户。</div></div><div class="notion-text notion-block-0667e5d1661243418edc785086abd4e3">参考haixin的文章<a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://www.haixin.io/article/notion-next-on-cf">《NotionNext建站-cloudflare版》</a>，这里做了优化</div><div class="notion-text notion-block-29f39047ef8b4ee18c2baacb9e864230">部署效果预览</div><div class="notion-row"><a target="_blank" rel="noopener noreferrer" class="notion-bookmark notion-block-102d88df0883480488de2d0f43a10720" href="https://cloudflare.tangly1024.com/"><div><div class="notion-bookmark-title">Notion Blog | 一个NotionNext搭建的博客</div><div class="notion-bookmark-description">一个NotionNext搭建的博客</div><div class="notion-bookmark-link"><div class="notion-bookmark-link-icon"><img src="https://www.notion.so/image/https%3A%2F%2Fcloudflare.tangly1024.com%2Ffavicon.ico?table=block&amp;id=102d88df-0883-4804-88de-2d0f43a10720&amp;t=102d88df-0883-4804-88de-2d0f43a10720" alt="Notion Blog | 一个NotionNext搭建的博客" loading="lazy" decoding="async"/></div><div class="notion-bookmark-link-text">https://cloudflare.tangly1024.com/</div></div></div><div class="notion-bookmark-image"><img style="object-fit:cover" src="https://www.notion.so/images/page-cover/nasa_robert_stewart_spacewalk_2.jpg" alt="Notion Blog | 一个NotionNext搭建的博客" loading="lazy" decoding="async"/></div></a></div><div class="notion-callout notion-gray_background_co notion-block-d059447a94494a2db0f44dad99c12db3"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="❓">❓</span></div><div class="notion-callout-text">CloudFlare版本是静态导出的，<b>不支持实时更新文章</b>，每次更改Notion内容后请手动部署站点。若需要实时动态更新请使用Vercel\Netlify\Zeabur\VPS部署方案。</div></div><div class="notion-callout notion-gray_background_co notion-block-25bf93b9208b809ca93dce161993f568"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text"><div class="notion-text notion-block-25bf93b9208b80219500fd4ac2ef3f93">CloudFlare部署方案，以及其他所有使用 静态导出的方案，默认都不支持NotionNext自带的搜索功能，必须集成Algolia插件才能实现全文搜索。

详情参考Algolia全文搜索插件获取帮助:</div><div class="notion-row"><a target="_blank" rel="noopener noreferrer" class="notion-bookmark notion-block-25bf93b9208b80a2828ecd0179f96135" href="https://docs.tangly1024.com/article/notion-next-algolia"><div><div class="notion-bookmark-title">Algolia搜索引擎 | NotionNext帮助手册</div><div class="notion-bookmark-description">NotionNext如何配置Algolia</div><div class="notion-bookmark-link"><div class="notion-bookmark-link-icon"><img src="https://www.notion.so/image/https%3A%2F%2Fdocs.tangly1024.com%2Ffavicon.ico?table=block&amp;id=25bf93b9-208b-80a2-828e-cd0179f96135&amp;t=25bf93b9-208b-80a2-828e-cd0179f96135" alt="Algolia搜索引擎 | NotionNext帮助手册" loading="lazy" decoding="async"/></div><div class="notion-bookmark-link-text">https://docs.tangly1024.com/article/notion-next-algolia</div></div></div><div class="notion-bookmark-image"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F01c82885-32ed-4da6-8c06-cf00a2df74c8%2Farhs6-ymx4f.webp?table=collection&amp;id=308a7afa-2d3d-46a4-b8ea-19debe72385f&amp;t=308a7afa-2d3d-46a4-b8ea-19debe72385f&amp;width=1080&amp;cache=v2&amp;t=25bf93b9-208b-80a2-828e-cd0179f96135" alt="Algolia搜索引擎 | NotionNext帮助手册" loading="lazy" decoding="async"/></div></a></div><figure class="notion-asset-wrapper notion-asset-wrapper-embed notion-block-336f93b9208b80e59beffa0e153b4d9f"></figure></div></div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-d4b1f02c61ae43c7bd29d07a9f92e151" data-id="d4b1f02c61ae43c7bd29d07a9f92e151"><span><div id="d4b1f02c61ae43c7bd29d07a9f92e151" class="notion-header-anchor"></div><a class="notion-hash-link" href="#d4b1f02c61ae43c7bd29d07a9f92e151" title="开始"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">开始</span></span></h2><div class="notion-text notion-block-37dd9972fc444dacab8875dbd4b30df2">访问CloudFlarePage</div><div class="notion-row"><a target="_blank" rel="noopener noreferrer" class="notion-bookmark notion-block-0e0ca42e54774400a8bba5724b510487" href="https://pages.cloudflare.com/"><div><div class="notion-bookmark-title">Cloudflare Pages</div><div class="notion-bookmark-description">Build your next application with Cloudflare Pages</div><div class="notion-bookmark-link"><div class="notion-bookmark-link-icon"><img src="https://www.notion.so/image/https%3A%2F%2Fpages.cloudflare.com%2Ffavicon.ico?table=block&amp;id=0e0ca42e-5477-4400-a8bb-a5724b510487&amp;t=0e0ca42e-5477-4400-a8bb-a5724b510487" alt="Cloudflare Pages" loading="lazy" decoding="async"/></div><div class="notion-bookmark-link-text">https://pages.cloudflare.com/</div></div></div><div class="notion-bookmark-image"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fblog.cloudflare.com%2Fcontent%2Fimages%2F2020%2F12%2Ftwitter-shared-link-18.png?table=block&amp;id=0e0ca42e-5477-4400-a8bb-a5724b510487&amp;t=0e0ca42e-5477-4400-a8bb-a5724b510487" alt="Cloudflare Pages" loading="lazy" decoding="async"/></div></a></div><div class="notion-blank notion-block-ce1cd5e7dc374c31beeb9c9233cc1236"> </div><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-47a47a05fee24c67b7183a18526d0e39" data-id="47a47a05fee24c67b7183a18526d0e39"><span><div id="47a47a05fee24c67b7183a18526d0e39" class="notion-header-anchor"></div><a class="notion-hash-link" href="#47a47a05fee24c67b7183a18526d0e39" title="创建项目"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">创建项目</span></span></h3><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-b268ff5efb4446c5affdbc8df83b530b"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:720px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2Fa755c05d-ce7e-492b-9286-0f9627efcc03%2FUntitled.png?table=block&amp;id=b268ff5e-fb44-46c5-affd-bc8df83b530b&amp;t=b268ff5e-fb44-46c5-affd-bc8df83b530b&amp;width=720&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-callout notion-brown_background_co notion-block-336f93b9208b802582e3e850c990cf44"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="⚠️">⚠️</span></div><div class="notion-callout-text"><div class="notion-text notion-block-336f93b9208b8043be1ee4c79141c414">注意，2026年新版的Cloudflare 默认引导部署Workers，但是NotionNext目前的代码不支持Workers动态。 暂时还是选择使用Pages静态部署：</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-336f93b9208b802fb516ec9cad84cd4c"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:384px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/attachment%3A2d9b1994-9717-41d8-a38c-0411c18f697e%3Aimage.png?table=block&amp;id=336f93b9-208b-802f-b516-ec9cad84cd4c&amp;t=336f93b9-208b-802f-b516-ec9cad84cd4c" alt="部署页面底部有个小小的Pages" loading="lazy" decoding="async"/><figcaption class="notion-asset-caption">部署页面底部有个小小的Pages</figcaption></div></figure></div></div><ol start="1" class="notion-list notion-list-numbered notion-block-67b97c086df4481d83da81f1a44ecdb9" style="list-style-type:decimal"><li>直接连接git</li><ol class="notion-list notion-list-numbered notion-block-67b97c086df4481d83da81f1a44ecdb9" style="list-style-type:lower-alpha"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-2e4689f5be2748c68216ff19f8fd8384"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:768px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F65d76318-f910-4f86-8d53-6bb905e24e2a%2FUntitled.png?table=block&amp;id=2e4689f5-be27-48c6-8216-ff19f8fd8384&amp;t=2e4689f5-be27-48c6-8216-ff19f8fd8384&amp;width=768&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ol></ol><ol start="2" class="notion-list notion-list-numbered notion-block-a1e01f1cb6094b9188d0929649879cf2" style="list-style-type:decimal"><li>导入项目</li><ol class="notion-list notion-list-numbered notion-block-a1e01f1cb6094b9188d0929649879cf2" style="list-style-type:lower-alpha"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-1d419df440d44246b6ef08382b11d877"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F022c0d20-5cf4-4516-9127-c6e9f56578ad%2FUntitled.png?table=block&amp;id=1d419df4-40d4-4246-b6ef-08382b11d877&amp;t=1d419df4-40d4-4246-b6ef-08382b11d877&amp;width=679.984375&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ol></ol><ol start="3" class="notion-list notion-list-numbered notion-block-427f2d904d804899b896721f2881f25c" style="list-style-type:decimal"><li>选择分支</li><ol class="notion-list notion-list-numbered notion-block-427f2d904d804899b896721f2881f25c" style="list-style-type:lower-alpha"><div class="notion-text notion-block-2677727a4a514e1b9d23061a775b6a3a">分支选择<code class="notion-inline-code"> deploy/cloudflare-support</code> ；</div><div class="notion-text notion-block-0b0f969fb1e7466dbb86e2dcaec6447b">在4.0.9之后的版本中，可以直接使用<code class="notion-inline-code">main</code>分支部署，无需切换分支</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-cd118a45370445828359490c6988b877"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:624px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2Fef41d434-9a32-4fc5-a37f-55132a999535%2FUntitled.png?table=block&amp;id=cd118a45-3704-4582-8359-490c6988b877&amp;t=cd118a45-3704-4582-8359-490c6988b877&amp;width=624&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><h3 class="notion-h notion-h2 notion-block-c28dbfb41d484afa999d055b17fb2a2f" data-id="c28dbfb41d484afa999d055b17fb2a2f"><span><div id="c28dbfb41d484afa999d055b17fb2a2f" class="notion-header-anchor"></div><a class="notion-hash-link" href="#c28dbfb41d484afa999d055b17fb2a2f" title="配置参数"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">配置参数</span></span></h3><div class="notion-text notion-block-51cd5dfc4b214b8bb7d9ff09b3ae80b3">来到页面下方的构建设置：</div><ul class="notion-list notion-list-disc notion-block-76f4a3c638e6480eaa0dd2848e74d57d"><li>构建命令填</li><ul class="notion-list notion-list-disc notion-block-76f4a3c638e6480eaa0dd2848e74d57d"></ul></ul><ul class="notion-list notion-list-disc notion-block-6360340134704247bd930d7e50dfd3dc"><li>输出根目录 <code class="notion-inline-code">out</code></li><ul class="notion-list notion-list-disc notion-block-6360340134704247bd930d7e50dfd3dc"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-28ebdcc486ad4926b268aa902a066593"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2Feecb1290-249a-46ef-aab5-782cf24310c1%2FUntitled.png?table=block&amp;id=28ebdcc4-86ad-4926-b268-aa902a066593&amp;t=28ebdcc4-86ad-4926-b268-aa902a066593&amp;width=651.9375&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ul></ul></ol></ol><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-cb9c62ec18594602a01879cff74a5eaf" data-id="cb9c62ec18594602a01879cff74a5eaf"><span><div id="cb9c62ec18594602a01879cff74a5eaf" class="notion-header-anchor"></div><a class="notion-hash-link" href="#cb9c62ec18594602a01879cff74a5eaf" title="环境变量"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">环境变量</span></span></h3><div class="notion-text notion-block-6cb6c5ca3910448c8c8c5f3cdfb7a244">配置效果如下</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-336f93b9208b80a7b425ecbd0dcf0ef5"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/attachment%3Ae7366ad2-43d4-449f-aed4-2109c7a7a716%3Aimage.png?table=block&amp;id=336f93b9-208b-80a7-b425-ecbd0dcf0ef5&amp;t=336f93b9-208b-80a7-b425-ecbd0dcf0ef5" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-ded3ca2cfeae423e9b91b33aea5d339c">配置说明</div><table class="notion-simple-table notion-block-2c7276df3ea74d6e80ccbdcc51cd9867"><tbody><tr class="notion-simple-table-row notion-block-36f00a4e06bc43918603abeb05e1078b"><td class="" style="width:120px"><div class="notion-simple-table-cell">变量名称</div></td><td class="" style="width:120px"><div class="notion-simple-table-cell"> 值</div></td></tr><tr class="notion-simple-table-row notion-block-09958f61b8034a51ad2023839db05c4b"><td class="" style="width:120px"><div class="notion-simple-table-cell">NODE_VERSION</div></td><td class="" style="width:120px"><div class="notion-simple-table-cell">18</div></td></tr><tr class="notion-simple-table-row notion-block-1f93618fad0d467c97b5be9eb68a7ae0"><td class="" style="width:120px"><div class="notion-simple-table-cell">VERCEL_ENV</div></td><td class="" style="width:120px"><div class="notion-simple-table-cell">production</div></td></tr><tr class="notion-simple-table-row notion-block-b1796e6dce824846bb57ea44d4e0f956"><td class="" style="width:120px"><div class="notion-simple-table-cell">NOTION_PAGE_ID</div></td><td class="" style="width:120px"><div class="notion-simple-table-cell">{您的Notion页面id}</div></td></tr></tbody></table><div class="notion-text notion-block-e8d91c66c0474650b56eff2a40b567df">最后点击保存并部署即可。</div><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-5f4bc4d3c02a48b0b91853db43f31526" data-id="5f4bc4d3c02a48b0b91853db43f31526"><span><div id="5f4bc4d3c02a48b0b91853db43f31526" class="notion-header-anchor"></div><a class="notion-hash-link" href="#5f4bc4d3c02a48b0b91853db43f31526" title="完成部署"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">完成部署</span></span></h3><div class="notion-text notion-block-2187d5929f5f474380cae3c8ed9ae20b">页面中心会显示您的访问域名</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-59595db9804844e6852b9b9723c0b9e0"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F30cba4fc-6da3-4a3d-a842-4b0e4443c8ac%2FUntitled.png?table=block&amp;id=59595db9-8048-44e6-852b-9b9723c0b9e0&amp;t=59595db9-8048-44e6-852b-9b9723c0b9e0&amp;width=707.96875&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-blank notion-block-9930f2c776da40f19523ec8981b50485"> </div><div class="notion-blank notion-block-36490ea3bde24e12850dca0de24b1930"> </div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-aa2a3fee610b40aab37c680a7034a070" data-id="aa2a3fee610b40aab37c680a7034a070"><span><div id="aa2a3fee610b40aab37c680a7034a070" class="notion-header-anchor"></div><a class="notion-hash-link" href="#aa2a3fee610b40aab37c680a7034a070" title="FAQ "><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">FAQ </span></span></h2><div class="notion-text notion-block-38ad4b690ed84e39b3ca49bb875f9f11">部署失败？如果你的构建日志中出现：
</div><div class="notion-text notion-block-f01187fcba1e41399ff5e72a13f1a335">可能是CLoudFlare升级环境导致不兼容，解决方法：<b>降级为旧版构建环境，然后点击重试</b></div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-ba9a4ae1d00d4249b9a259952871e563"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F66804e4e-228b-47a6-b8b2-db5549830d2e%2FUntitled.png?table=block&amp;id=ba9a4ae1-d00d-4249-b9a2-59952871e563&amp;t=ba9a4ae1-d00d-4249-b9a2-59952871e563&amp;width=707.96875&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-06ef6e3fd8b449ba87b3611f423676ac"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F3dfcc002-9e87-458c-8933-cfb732428a35%2FUntitled.png?table=block&amp;id=06ef6e3f-d8b4-49ba-87b3-611f423676ac&amp;t=06ef6e3f-d8b4-49ba-87b3-611f423676ac&amp;width=707.984375&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-blank notion-block-c3fd6e32c98f43e2a2c18c6b1467ee60"> </div><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-107f93b9208b806595bfcc3421bc9241" data-id="107f93b9208b806595bfcc3421bc9241"><span><div id="107f93b9208b806595bfcc3421bc9241" class="notion-header-anchor"></div><a class="notion-hash-link" href="#107f93b9208b806595bfcc3421bc9241" title="需要帮助？"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">需要帮助？</span></span></h3><div class="notion-text notion-block-107f93b9208b8029bfafc5ef325fdba1">如果你的部署异常，没有出现一个绿色的勾，通常是代码修改异常或者配置错误导致，点击右侧的查看详情，获取详细的部署日志：</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-107f93b9208b804ba8fbe886f0e47beb"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F95527329-dee1-4a04-a653-5b73647d5c73%2Fimage.png?table=block&amp;id=107f93b9-208b-804b-a8fb-e886f0e47beb&amp;t=107f93b9-208b-804b-a8fb-e886f0e47beb&amp;width=707.984375&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-64af4c7a3d214256be4de78065be9f3a">在构建日志这一栏可以看到所有详细的错误信息，根据错误日志进行排查问题，如果无法自行排查，可以将日志复制或截图，寻求他人帮助。</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-107f93b9208b803685d6de4bba75a90a"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F3ef8720a-b6e7-4c76-a39d-c3cdc6f4d82a%2Fimage.png?table=block&amp;id=107f93b9-208b-8036-85d6-de4bba75a90a&amp;t=107f93b9-208b-8036-85d6-de4bba75a90a&amp;width=707.984375&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-2640122e07014bfa8fb2aa3fa5a346ca" data-id="2640122e07014bfa8fb2aa3fa5a346ca"><span><div id="2640122e07014bfa8fb2aa3fa5a346ca" class="notion-header-anchor"></div><a class="notion-hash-link" href="#2640122e07014bfa8fb2aa3fa5a346ca" title="CloudFlarePage如何绑定自定义域名？"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">CloudFlarePage如何绑定自定义域名？</span></span></h2><div class="notion-text notion-block-a6b2b409f5db4c389a8c2496a4ccf8e9">项目主页找到<code class="notion-inline-code">自定义域</code>，找到下方设置自定义域</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-2ec1449b9bc44b33b6df972d47250393"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F540d349c-3a54-4ad6-8f35-3c7aab9029f3%2FUntitled.png?table=block&amp;id=2ec1449b-9bc4-4b33-b6df-972d47250393&amp;t=2ec1449b-9bc4-4b33-b6df-972d47250393&amp;width=707.953125&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-a24cabd53f09455296214fdb2f571038">填写域名并继续</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-56db2dfc09e94e1eaa72bd2accd48601"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F5ec74a21-2da9-4738-90ab-219b8dff3c4a%2FUntitled.png?table=block&amp;id=56db2dfc-09e9-4e1e-aa72-bd2accd48601&amp;t=56db2dfc-09e9-4e1e-aa72-bd2accd48601&amp;width=707.96875&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-85c463adb69d4aa1bd78ce3ad8a1561b">按照要求在域名服务商后台配置一个CNAME转发</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-67cab9e54a694688b0d37b8153fd26af"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F0ede5959-b1d6-4647-9535-dc6d7931df22%2FUntitled.png?table=block&amp;id=67cab9e5-4a69-4688-b0d3-7b8153fd26af&amp;t=67cab9e5-4a69-4688-b0d3-7b8153fd26af&amp;width=707.96875&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><ul class="notion-list notion-list-disc notion-block-c3315888982f4f4ca4a77c08887076b4"><li>CNAME转发示例</li><ul class="notion-list notion-list-disc notion-block-c3315888982f4f4ca4a77c08887076b4"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-13edb7cad5d144a195820500ba4592a3"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F83f0ce76-4f25-4d79-b3a1-8cd7f05eed54%2FUntitled.png?table=block&amp;id=13edb7ca-d5d1-44a1-9582-0500ba4592a3&amp;t=13edb7ca-d5d1-44a1-9582-0500ba4592a3&amp;width=679.984375&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ul></ul><ul class="notion-list notion-list-disc notion-block-7840351e977c4f91ac2c76ace8127898"><li>点击下方的激活域，由于我使用的域名商本身就是cloudflare，故此步骤只需几秒即可完成验证。</li><ul class="notion-list notion-list-disc notion-block-7840351e977c4f91ac2c76ace8127898"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-e63adf7b0a7a4c129833a2e554c0c5f0"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F3a5dfe5f-14ed-40b4-bb50-76b94fe68fbd%2FUntitled.png?table=block&amp;id=e63adf7b-0a7a-4c12-9833-a2e554c0c5f0&amp;t=e63adf7b-0a7a-4c12-9833-a2e554c0c5f0&amp;width=679.984375&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ul></ul><div class="notion-blank notion-block-336f93b9208b809aaaa1d8ad59ba71d4"> </div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-336f93b9208b80d8954adc1c01fa78fd" data-id="336f93b9208b80d8954adc1c01fa78fd"><span><div id="336f93b9208b80d8954adc1c01fa78fd" class="notion-header-anchor"></div><a class="notion-hash-link" href="#336f93b9208b80d8954adc1c01fa78fd" title="Hooks 触发部署"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">Hooks 触发部署</span></span></h2><div class="notion-blank notion-block-336f93b9208b80dca93cf1aca4188705"> </div><div class="notion-text notion-block-336f93b9208b80d28248eed76eadc16d">CloudFlare 支持和Vercel 类似的hooks 功能，后台生成一个调用地址，即可触发站点重新部署，用于更新文件和配置等。</div><div class="notion-text notion-block-336f93b9208b804cb2caf97646869943">在项目的设置页面，构建栏目下的部署挂钩。点击加号➕新增一个hooks即可</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-336f93b9208b803484bbce1bd2dc39bc"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/attachment%3A7ba8effd-9e55-4a93-9acd-3f408abd0a7c%3Aimage.png?table=block&amp;id=336f93b9-208b-8034-84bb-ce1bd2dc39bc&amp;t=336f93b9-208b-8034-84bb-ce1bd2dc39bc" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-336f93b9208b80dc9f41c022c1b4a5b4">创建挂钩时，要指定你部署的github代码分支，以及随意起一个挂钩名称；</div><div class="notion-row notion-block-336f93b9208b80f39dddfae75f443de4"><div class="notion-column notion-block-336f93b9208b801a99e2e274802cf0ca" style="width:calc((100% - (1 * min(32px, 4vw))) * 0.5)"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-336f93b9208b80c58f9bfd22d65b5dab"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:403.00347900390625px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/attachment%3A82fbe880-dda2-414b-b018-3f460d8202e6%3Aimage.png?table=block&amp;id=336f93b9-208b-80c5-8f9b-fd22d65b5dab&amp;t=336f93b9-208b-80c5-8f9b-fd22d65b5dab" alt="notion image" loading="lazy" decoding="async"/></div></figure></div><div class="notion-spacer"></div><div class="notion-column notion-block-336f93b9208b80dc971dfbcbdaefd6e8" style="width:calc((100% - (1 * min(32px, 4vw))) * 0.5)"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-336f93b9208b800c8454e42efa246500"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/attachment%3A167c38e7-d1c6-4702-9bda-dddd69617554%3Aimage.png?table=block&amp;id=336f93b9-208b-800c-8454-e42efa246500&amp;t=336f93b9-208b-800c-8454-e42efa246500" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-336f93b9208b80e8ae1ef7541cc267fc">创建后会生成一个webhook链接，点击复制链接保存使用。</div><div class="notion-blank notion-block-336f93b9208b8079821ee10559bc78be"> </div></div><div class="notion-spacer"></div></div><div class="notion-blank notion-block-336f93b9208b80dfb276c70bdaadd642"> </div><div class="notion-text notion-block-336f93b9208b808884a5e6643fb42434">需要注意，CloudFlare的hook 和 Vercel 不一样：</div><ul class="notion-list notion-list-disc notion-block-336f93b9208b800c90bfc76ed8c38539"><li><b>Vercel webhook</b> 👉 GET 也行（在浏览器地址栏输入Webhook网址即可 简单触发）</li></ul><ul class="notion-list notion-list-disc notion-block-336f93b9208b80d3b978f89c6b05be66"><li><b>Cloudflare Deploy Hook</b> 👉 只允许 POST（更安全）</li><ul class="notion-list notion-list-disc notion-block-336f93b9208b80d3b978f89c6b05be66"><div class="notion-text notion-block-336f93b9208b80a8ae79fdacaf927ccb">浏览器访问会提示 <code class="notion-inline-code">method_not_allowed</code></div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-336f93b9208b8092a4dbfeae398e8e23"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:666.9791870117188px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/attachment%3A7f8e94aa-7f9e-42e3-b7a2-39a77c281844%3Aimage.png?table=block&amp;id=336f93b9-208b-8092-a4db-feae398e8e23&amp;t=336f93b9-208b-8092-a4db-feae398e8e23" alt="notion image" loading="lazy" decoding="async"/></div></figure></ul></ul><div class="notion-text notion-block-336f93b9208b802db0d6e658a169e26f">👉 防止被随便浏览器点一下就触发部署</div><div class="notion-blank notion-block-336f93b9208b8095bed3c75b8f07080a"> </div><div class="notion-text notion-block-336f93b9208b80eca1a4d18f8118b31d">Windows/Mac/Linux可以用 终端命令行输入以下命令触发</div><div class="notion-text notion-block-336f93b9208b802ea4abef8d119c0e74">当页面显示如下内容，说明已经触发了重新部署</div><div class="notion-row notion-block-336f93b9208b80f382e6cf6079ac62fc"><div class="notion-column notion-block-336f93b9208b809c8cb0c78bcc138c59" style="width:calc((100% - (1 * min(32px, 4vw))) * 0.5)"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-336f93b9208b806fa04cd5fd9b181b3a"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/attachment%3A3a626211-80cd-40ed-9127-9c228de25b15%3Aimage.png?table=block&amp;id=336f93b9-208b-806f-a04c-d5fd9b181b3a&amp;t=336f93b9-208b-806f-a04c-d5fd9b181b3a" alt="notion image" loading="lazy" decoding="async"/></div></figure></div><div class="notion-spacer"></div><div class="notion-column notion-block-336f93b9208b80aabf1cf530495103a1" style="width:calc((100% - (1 * min(32px, 4vw))) * 0.5)"></div><div class="notion-spacer"></div></div></main></div>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[NotionNext开发先导]]></title>
            <link>https://docs.tangly1024.com/article/how-to-develop-with-notion-next</link>
            <guid>https://docs.tangly1024.com/article/how-to-develop-with-notion-next</guid>
            <pubDate>Sun, 13 Nov 2022 00:00:00 GMT</pubDate>
            <description><![CDATA[小白入门如何开发notionnext，下载NotionNext、启动NotionNext、提交合并到NotionNext等。]]></description>
            <content:encoded><![CDATA[<div id="notion-article" class="mx-auto overflow-hidden "><main class="notion light-mode notion-page notion-block-3795d7d35ef64bd49510402d7afa8ffa"><div class="notion-viewport"></div><div class="notion-collection-page-properties"></div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-9260aee5457e45aeb3cd494d8a75dc16" data-id="9260aee5457e45aeb3cd494d8a75dc16"><span><div id="9260aee5457e45aeb3cd494d8a75dc16" class="notion-header-anchor"></div><a class="notion-hash-link" href="#9260aee5457e45aeb3cd494d8a75dc16" title="前言"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">前言</span></span></h2><div class="notion-text notion-block-c0ccb33190ff4a6c827f0d3e05e30296">在进行二次开发之前，您需要了解到：NotionNext本身支持大量的自定义配置，开发之前，请先访问《<a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://docs.tangly1024.com/article/how-to-config-notion-next">配置手册</a>》获取帮助、配置您的站点，例如：</div><ul class="notion-list notion-list-disc notion-block-9ea9ffe5c73d4898abdc3ebd09284b5d"><li> <code class="notion-inline-code">blog.config.js</code> 文件中可以修改站点的基础信息、主题、语言、评论插件等核心配置</li></ul><ul class="notion-list notion-list-disc notion-block-ced722c3e5664c2c9e1f1448712887b6"><li>每个主题下都有一个配置文件<code class="notion-inline-code">config_[theme].js</code>，以便用户配置自己的页面个性化。</li><ul class="notion-list notion-list-disc notion-block-ced722c3e5664c2c9e1f1448712887b6"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-732c22c93c064aafb1b93f843e850315"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:384px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F77945898-5301-41f5-b05a-28785d5e4af2%2FUntitled.png?table=block&amp;id=732c22c9-3c06-4aaf-b1b9-3f843e850315&amp;t=732c22c9-3c06-4aaf-b1b9-3f843e850315&amp;width=384&amp;cache=v2" alt="NotionNext 代码结构" loading="lazy" decoding="async"/><figcaption class="notion-asset-caption">NotionNext 代码结构</figcaption></div></figure></ul></ul><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-2074a1f2a3ac4638b6756366e8fed971" data-id="2074a1f2a3ac4638b6756366e8fed971"><span><div id="2074a1f2a3ac4638b6756366e8fed971" class="notion-header-anchor"></div><a class="notion-hash-link" href="#2074a1f2a3ac4638b6756366e8fed971" title="自定义脚本"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">自定义脚本</span></span></h3><div class="notion-text notion-block-c3714a88d8824364af24d99657b5fb07">NotionNext操作手册中，有关于自定义脚本和样式的引入方式；即：</div><ol start="1" class="notion-list notion-list-numbered notion-block-9229a5ceb18a4e5d8dcfd54625c686a9" style="list-style-type:decimal"><li>在<code class="notion-inline-code">/public/js/custom.js</code> <code class="notion-inline-code">/public/css/custom.css</code> 中引入您的脚本，就可以实现任意的页面功能。</li></ol><ol start="2" class="notion-list notion-list-numbered notion-block-4d01c34685bf42e7aafbd0cdd64b7d48" style="list-style-type:decimal"><li>在<code class="notion-inline-code">blog.config.js</code>的<code class="notion-inline-code">CUSTOM_EXTERNAL_JS</code>、<code class="notion-inline-code">CUSTOM_EXTERNAL_CSS</code>中也可以引入第三方的脚本。</li></ol><div class="notion-callout notion-gray_background_co notion-block-355a34550db944b39abc61e355a483f1"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text">用这两种方式引入脚本，即使本机上没有安装nodejs等开发环境，也可以直接在浏览器控制台中编写调试。</div></div><div class="notion-blank notion-block-e6f83fc587fa4386ae21ef789e849300"> </div><h4 class="notion-h notion-h3 notion-h-indent-2 notion-block-3768bf2f827e45a1b9b5a012a1c68de4" data-id="3768bf2f827e45a1b9b5a012a1c68de4"><span><div id="3768bf2f827e45a1b9b5a012a1c68de4" class="notion-header-anchor"></div><a class="notion-hash-link" href="#3768bf2f827e45a1b9b5a012a1c68de4" title="Notion中自定义JS和CSS"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">Notion中自定义JS和CSS</span></span></h4><div class="notion-text notion-block-b6c85adb2921449d9ef930bda74b62c6">在4.2.0之后的版本中，您可以直接在Notion中指定网页上的样式，以及执行的脚本，只需在NotionConfig中配置<code class="notion-inline-code">GLOBAL_CSS</code>属性以及<code class="notion-inline-code">GLOBAL_JS</code>属性即可，如下图示例：</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-3a8bb0a5e1af4844a6d6fd6cdc9d91c9"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F12750bae-1a44-4dfc-ad5e-09260f5e1142%2FUntitled.png?table=block&amp;id=3a8bb0a5-e1af-4844-a6d6-fd6cdc9d91c9&amp;t=3a8bb0a5-e1af-4844-a6d6-fd6cdc9d91c9&amp;width=738&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-blank notion-block-1566069c098a435cadba07f20e4a3c51"> </div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-480c2e6f533448ceaa03077e3f9c5378" data-id="480c2e6f533448ceaa03077e3f9c5378"><span><div id="480c2e6f533448ceaa03077e3f9c5378" class="notion-header-anchor"></div><a class="notion-hash-link" href="#480c2e6f533448ceaa03077e3f9c5378" title="自行开发"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">自行开发</span></span></h2><div class="notion-text notion-block-8fdd329093f8405b949ae600b3335fd5">如果上述的配置方式，不能满足您的需要，例如新增组件、深度定制等等。您可以选择在github上<a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://github.com/tangly1024/NotionNext/issues/new/choose">发起issue</a>，提出改进页面的建议，或者遵循此教程，进行您的开发之旅。</div><div class="notion-callout notion-gray_background_co notion-block-76e016b0fe7f42cdb8ea0a339f0a3ac2"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text">可选Codespaces云开发，以及本地开发两种方案。</div></div><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-a575776719214bebae8cf95be491fbd0" data-id="a575776719214bebae8cf95be491fbd0"><span><div id="a575776719214bebae8cf95be491fbd0" class="notion-header-anchor"></div><a class="notion-hash-link" href="#a575776719214bebae8cf95be491fbd0" title="一、云开发(Codespaces)"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">一、云开发(Codespaces)</span></span></h3><div class="notion-callout notion-gray_background_co notion-block-a270ea5dbfa142588dc670bec64297ea"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text">这是一个可选方案，相比本地开发，您不需要在电脑上安装环境；直接将Github仓库导入到云开发环境，在线编辑即可。
Codespaces是Github官方提供的云开发环境。</div></div><details class="notion-toggle notion-block-076eb183422f4bde9e6a53250b912ce5"><summary><h4 class="notion-h notion-h3 notion-h-indent-2 notion-block-076eb183422f4bde9e6a53250b912ce5" data-id="076eb183422f4bde9e6a53250b912ce5"><span><div id="076eb183422f4bde9e6a53250b912ce5" class="notion-header-anchor"></div><span class="notion-h-title">导入启动项目</span></span></h4></summary><div><ol start="1" class="notion-list notion-list-numbered notion-block-6c4412ff9c1a4fb99dd254b1c9e1fc6b" style="list-style-type:decimal"><li>点击Codespaces</li><ol class="notion-list notion-list-numbered notion-block-6c4412ff9c1a4fb99dd254b1c9e1fc6b" style="list-style-type:lower-alpha"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-528cee998bb64306a8f2eaa9697828b9"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F7a08e677-7d7c-4aa2-bd1c-664318c50245%2FUntitled.png?table=block&amp;id=528cee99-8bb6-4306-a8f2-eaa9697828b9&amp;t=528cee99-8bb6-4306-a8f2-eaa9697828b9&amp;width=1597&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ol></ol><ol start="2" class="notion-list notion-list-numbered notion-block-2e8ae35157104d71aab10da6a7d05db2" style="list-style-type:decimal"><li>点击新建代码空间</li><ol class="notion-list notion-list-numbered notion-block-2e8ae35157104d71aab10da6a7d05db2" style="list-style-type:lower-alpha"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-baa35a0416fd408eb1fc8e9182c5385a"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2Fd1cd6c5c-1d5c-4e3d-ac33-f30abcdc05b2%2FUntitled.png?table=block&amp;id=baa35a04-16fd-408e-b1fc-8e9182c5385a&amp;t=baa35a04-16fd-408e-b1fc-8e9182c5385a&amp;width=1865&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ol></ol><ol start="3" class="notion-list notion-list-numbered notion-block-d7d10d85f68f408cb8ef4f40eaa703ca" style="list-style-type:decimal"><li>导入项目，并选择代码分支、以及云环境的服务器配置，然后点击Create codespacee</li><ol class="notion-list notion-list-numbered notion-block-d7d10d85f68f408cb8ef4f40eaa703ca" style="list-style-type:lower-alpha"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-0c9f18a07b114ce7b33375a8b45b6283"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:480px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2Ff15f19d0-c410-47fd-a476-a838537259a5%2FUntitled.png?table=block&amp;id=0c9f18a0-7b11-4ce7-b333-75a8b45b6283&amp;t=0c9f18a0-7b11-4ce7-b333-75a8b45b6283&amp;width=480&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-749e86a9ca24430893e1a58093f9e7e1"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:480px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F893b5482-6d81-4009-9929-6f8ebc24159c%2FUntitled.png?table=block&amp;id=749e86a9-ca24-4308-93e1-a58093f9e7e1&amp;t=749e86a9-ca24-4308-93e1-a58093f9e7e1&amp;width=480&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ol></ol><ol start="4" class="notion-list notion-list-numbered notion-block-37e3ba48c3f04b29be535755834ab794" style="list-style-type:decimal"><li>等待几分钟，您的云开发环境即可搭建</li><ol class="notion-list notion-list-numbered notion-block-37e3ba48c3f04b29be535755834ab794" style="list-style-type:lower-alpha"><ul class="notion-list notion-list-disc notion-block-148433338d7b47608ddb67e5d8b1d578"><li>在终端中输入 <code class="notion-inline-code">yarn</code> 即可安装依赖的环境</li><ul class="notion-list notion-list-disc notion-block-148433338d7b47608ddb67e5d8b1d578"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-b9f94816d3af4666af9edc18325bfc0b"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F81bc7970-6c99-4ca1-8c20-2d67a6f81065%2FUntitled.png?table=block&amp;id=b9f94816-d3af-4666-af9e-dc18325bfc0b&amp;t=b9f94816-d3af-4666-af9e-dc18325bfc0b&amp;width=1920&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ul></ul><ul class="notion-list notion-list-disc notion-block-d0892d983069434c87ca974448cb7d49"><li>等上一步安装全部完成（约3分钟）后，在终端输入 <code class="notion-inline-code">yarn dev</code>  即可开始实时调试 </li><ul class="notion-list notion-list-disc notion-block-d0892d983069434c87ca974448cb7d49"><div class="notion-text notion-block-27e099d7dc084780b466c2151ca4ff10">终端会提示以下内容，说明服务启动成功：</div><div class="notion-text notion-block-82a05381530346c581dc5c8fd1a28f43">点击右下角的在浏览器中打开，即可开启调试页面。</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-16447d82fcb94138a9266f7c3b14cc7f"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F03b01693-399b-4e78-9be0-12e35c91d420%2FUntitled.png?table=block&amp;id=16447d82-fcb9-4138-a926-6f7c3b14cc7f&amp;t=16447d82-fcb9-4138-a926-6f7c3b14cc7f&amp;width=1590&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ul></ul><ul class="notion-list notion-list-disc notion-block-1b140c1f1e8c48d1b186837a2c3d7320"><li>调试效果</li><ul class="notion-list notion-list-disc notion-block-1b140c1f1e8c48d1b186837a2c3d7320"><div class="notion-text notion-block-ae7f1a47ce67404dad0d7cf91f183c54">github 会临时分配给您一个临时的域名，用于开发调试</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-1d6f865eb15541d1a77c7b203143ed79"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F6b20906c-e282-49a4-b608-a5b6c41bff9f%2FUntitled.png?table=block&amp;id=1d6f865e-b155-41d1-a77c-7b203143ed79&amp;t=1d6f865e-b155-41d1-a77c-7b203143ed79&amp;width=1481&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ul></ul></ol></ol></div></details><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-d9f9cff0c36644dab1383d0f93a7434b" data-id="d9f9cff0c36644dab1383d0f93a7434b"><span><div id="d9f9cff0c36644dab1383d0f93a7434b" class="notion-header-anchor"></div><a class="notion-hash-link" href="#d9f9cff0c36644dab1383d0f93a7434b" title="二、 本地开发"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">二、 本地开发</span></span></h3><details class="notion-toggle notion-block-c37a6b9db28b44b3888c14a643ff264a"><summary><h4 class="notion-h notion-h3 notion-h-indent-2 notion-block-c37a6b9db28b44b3888c14a643ff264a" data-id="c37a6b9db28b44b3888c14a643ff264a"><span><div id="c37a6b9db28b44b3888c14a643ff264a" class="notion-header-anchor"></div><span class="notion-h-title">1.准备开发环境</span></span></h4></summary><div><div class="notion-callout notion-gray_background_co notion-block-8de45db1f3a84b50bfd8ae2b499fd28b"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text">您的电脑上需要有一个开发环境NodeJs、以及代码编辑器VSCode，</div></div><ol start="1" class="notion-list notion-list-numbered notion-block-751fd83a20854f5784274d99be6cc047" style="list-style-type:decimal"><li>NodeJS 运行环境</li><ol class="notion-list notion-list-numbered notion-block-751fd83a20854f5784274d99be6cc047" style="list-style-type:lower-alpha"><details class="notion-toggle notion-block-c9685006849440a48ee073231c410075"><summary>安装步骤</summary><div><ul class="notion-list notion-list-disc notion-block-8dff4dcf17914212a990b70015bccc2f"><li>windows操作系统下，在官网下载安装最新版的NodeJs即可</li><ul class="notion-list notion-list-disc notion-block-8dff4dcf17914212a990b70015bccc2f"><div class="notion-row"><a target="_blank" rel="noopener noreferrer" class="notion-bookmark notion-block-a71c20223bfd4875bfe1480bb3cd132e" href="https://nodejs.org/zh-cn/#home-downloadhead"><div><div class="notion-bookmark-title">Node.js</div><div class="notion-bookmark-description">Node.js® is a JavaScript runtime built on Chrome&#x27;s V8 JavaScript engine.</div><div class="notion-bookmark-link"><div class="notion-bookmark-link-icon"><img src="https://www.notion.so/image/https%3A%2F%2Fnodejs.org%2Fstatic%2Fimages%2Ffavicons%2Ffavicon.ico?table=block&amp;id=a71c2022-3bfd-4875-bfe1-480bb3cd132e&amp;t=a71c2022-3bfd-4875-bfe1-480bb3cd132e" alt="Node.js" loading="lazy" decoding="async"/></div><div class="notion-bookmark-link-text">https://nodejs.org/zh-cn/#home-downloadhead</div></div></div><div class="notion-bookmark-image"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fnodejs.org%2Fstatic%2Fimages%2Flogo-hexagon-card.png?table=block&amp;id=a71c2022-3bfd-4875-bfe1-480bb3cd132e&amp;t=a71c2022-3bfd-4875-bfe1-480bb3cd132e" alt="Node.js" loading="lazy" decoding="async"/></div></a></div><div class="notion-callout notion-gray_background_co notion-block-12df93b9208b80279182f9354e2931cb"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text"><div class="notion-text notion-block-82ca6341e12f4a5ba85eeace09788956">至少要 ≥ 18.17.0 以上版本的NodeJS才支持本项目；例如18.20.4；

部分更高版本的NodeJS会存在兼容性问题，请避开使用以下版本的NodeJs：20.17.~。</div></div></div></ul></ul><ul class="notion-list notion-list-disc notion-block-caa08e234e814376a941eab80fbc23d0"><li>安装成功检验</li><ul class="notion-list notion-list-disc notion-block-caa08e234e814376a941eab80fbc23d0"><div class="notion-text notion-block-19339e9a09b347bbb0be17f38f3c1743">安装成功，测试安装是否成功，运行CMD，分别输入node -v 和 npm -v 分别查看node和npm的版本号，如下图所示： </div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-4deccacd11b3469186c6191e8a66fe07"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:560px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2Fa3acaf90-25b0-4689-b548-b79e1681e0a0%2FUntitled.png?table=block&amp;id=4deccacd-11b3-4691-86c6-191e8a66fe07&amp;t=4deccacd-11b3-4691-86c6-191e8a66fe07&amp;width=560&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-callout notion-gray_background_co notion-block-05a8602629e54fdb827073c5b965cdec"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text">node是基础运行环境，npm是依赖包的管理组件</div></div><div class="notion-callout notion-gray_background_co notion-block-1d2f93b9208b80e2b842e0888be0b582"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text"><div class="notion-text notion-block-1d2f93b9208b8084a86ef33b75ab0e15">如果执行 npm -v 出现异常 <b>npm : 无法加载文件 D:\nodejs\npm.ps1 ，可以参考此文: </b></div><div class="notion-row"><a target="_blank" rel="noopener noreferrer" class="notion-bookmark notion-block-1d2f93b9208b803bbb63eb0a2b807fb2" href="https://blog.csdn.net/qq_29385297/article/details/144445759"><div><div class="notion-bookmark-title">npm : 无法加载文件 D:\nodejs\npm.ps1-CSDN博客</div><div class="notion-bookmark-description">文章浏览阅读1.1k次，点赞11次，收藏5次。npm : 无法加载文件 D:\ nodejs\ npm.ps1</div><div class="notion-bookmark-link"><div class="notion-bookmark-link-icon"><img src="https://www.notion.so/image/https%3A%2F%2Fg.csdnimg.cn%2Fstatic%2Flogo%2Ffavicon32.ico?table=block&amp;id=1d2f93b9-208b-803b-bb63-eb0a2b807fb2&amp;t=1d2f93b9-208b-803b-bb63-eb0a2b807fb2" alt="npm : 无法加载文件 D:\nodejs\npm.ps1-CSDN博客" loading="lazy" decoding="async"/></div><div class="notion-bookmark-link-text">https://blog.csdn.net/qq_29385297/article/details/144445759</div></div></div></a></div></div></div></ul></ul></div></details></ol></ol><ol start="2" class="notion-list notion-list-numbered notion-block-2dc62575b8bf403c80193503daa631a9" style="list-style-type:decimal"><li>VsCode 编辑器</li><ol class="notion-list notion-list-numbered notion-block-2dc62575b8bf403c80193503daa631a9" style="list-style-type:lower-alpha"><details class="notion-toggle notion-block-1b77c7ce09fc4047b01588ee450854ff"><summary>安装下载</summary><div><div class="notion-row"><a target="_blank" rel="noopener noreferrer" class="notion-bookmark notion-block-365800c287c54bbeaa4dff56f0eb3ef2" href="https://code.visualstudio.com/download"><div><div class="notion-bookmark-title">Download Visual Studio Code - Mac, Linux, Windows</div><div class="notion-bookmark-description">Visual Studio Code is free and available on your favorite platform - Linux, macOS, and Windows. Download Visual Studio Code to experience a redefined code editor, optimized for building and debugging modern web and cloud applications.</div><div class="notion-bookmark-link"><div class="notion-bookmark-link-icon"><img src="https://www.notion.so/image/https%3A%2F%2Fcode.visualstudio.com%2Ffavicon.ico?table=block&amp;id=365800c2-87c5-4bbe-aa4d-ff56f0eb3ef2&amp;t=365800c2-87c5-4bbe-aa4d-ff56f0eb3ef2" alt="Download Visual Studio Code - Mac, Linux, Windows" loading="lazy" decoding="async"/></div><div class="notion-bookmark-link-text">https://code.visualstudio.com/download</div></div></div><div class="notion-bookmark-image"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fcode.visualstudio.com%2Fopengraphimg%2Fopengraph-home.png?table=block&amp;id=365800c2-87c5-4bbe-aa4d-ff56f0eb3ef2&amp;t=365800c2-87c5-4bbe-aa4d-ff56f0eb3ef2" alt="Download Visual Studio Code - Mac, Linux, Windows" loading="lazy" decoding="async"/></div></a></div></div></details><details class="notion-toggle notion-block-0c717346ea8c4fee83abe2e5d76322a4"><summary>设置中文</summary><div><div class="notion-row"><a target="_blank" rel="noopener noreferrer" class="notion-bookmark notion-block-7b1d3d65563844fa8da1e10a4a4b3cfb" href="https://zhuanlan.zhihu.com/p/263036716"><div><div class="notion-bookmark-title">Visual Studio Code如何设置中文</div><div class="notion-bookmark-description">Visual Studio Code是一款支持多种语言和格式的编辑器，那么，怎么把界面设置成中文的呢？今天就和大家一起把Visual Studio Code界面设置成中文 打开Visual Studio Code 点击&quot;应用&quot;按钮 输入&quot;Chinese (Simplified) Language Pack for Visual Studio Code&quot;并敲回车键 点击第一个选项 点击Install 点击Restart Now 这样就设置完成了 点击下方链接 点击Install 点击Continue 如果浏览器有拦截，请点击打开（各浏览器的界面不同） 点击Install 最后点击Restart Now即可 END 喜欢请点赞+关注</div><div class="notion-bookmark-link"><div class="notion-bookmark-link-icon"><img src="https://www.notion.so/image/https%3A%2F%2Fstatic.zhihu.com%2Fheifetz%2Ffavicon.ico?table=block&amp;id=7b1d3d65-5638-44fa-8da1-e10a4a4b3cfb&amp;t=7b1d3d65-5638-44fa-8da1-e10a4a4b3cfb" alt="Visual Studio Code如何设置中文" loading="lazy" decoding="async"/></div><div class="notion-bookmark-link-text">https://zhuanlan.zhihu.com/p/263036716</div></div></div><div class="notion-bookmark-image"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fpicd.zhimg.com%2Fv2-34ac26de1320cdb7e5cba8c22038bdbc_r.jpg%3Fsource%3D172ae18b?table=block&amp;id=7b1d3d65-5638-44fa-8da1-e10a4a4b3cfb&amp;t=7b1d3d65-5638-44fa-8da1-e10a4a4b3cfb" alt="Visual Studio Code如何设置中文" loading="lazy" decoding="async"/></div></a></div></div></details></ol></ol><div class="notion-callout notion-teal_background_co notion-block-cc50122f3d42471bafa698457f42dea1"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text">相关阅读<ul class="notion-list notion-list-disc notion-block-023f721581af4d299aba11cbd5a1d6da"><li><a target="_blank" rel="noopener noreferrer" class="notion-link" href="http://c.biancheng.net/view/9338.html">NodeJS是什么</a></li></ul><ul class="notion-list notion-list-disc notion-block-0a1b000f0fc5474387ec47ab51bd5b36"><li><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://www.runoob.com/nodejs/nodejs-npm.html">NPM使用介绍</a></li></ul><ul class="notion-list notion-list-disc notion-block-abbecf2818b546ad9dfbbe3e5935e9df"><li><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://www.jianshu.com/p/163bfc500549">什么是React</a></li></ul></div></div></div></details><details class="notion-toggle notion-block-de251775f4284b0bb4cfb363d05f3296"><summary><h4 class="notion-h notion-h3 notion-h-indent-2 notion-block-de251775f4284b0bb4cfb363d05f3296" data-id="de251775f4284b0bb4cfb363d05f3296"><span><div id="de251775f4284b0bb4cfb363d05f3296" class="notion-header-anchor"></div><span class="notion-h-title">2.导入启动项目</span></span></h4></summary><div><ol start="1" class="notion-list notion-list-numbered notion-block-394aa75c737940d4b19eab1c2ccfbbb7" style="list-style-type:decimal"><li>下载您的代码</li><ol class="notion-list notion-list-numbered notion-block-394aa75c737940d4b19eab1c2ccfbbb7" style="list-style-type:lower-alpha"><details class="notion-toggle notion-block-847a7718361149e0a2e7d44e75333d8f"><summary>安装Github Desktop</summary><div><div class="notion-row"><a target="_blank" rel="noopener noreferrer" class="notion-bookmark notion-block-8c0de4dd63f3401f9550d27010c93460" href="https://desktop.github.com/"><div><div class="notion-bookmark-title">GitHub Desktop</div><div class="notion-bookmark-description">Checkout branches with pull requests and view CI statuses See all open pull requests for your repositories and check them out as if they were a local branch, even if they&#x27;re from upstream branches or forks. See which pull requests pass commit status checks, too!</div><div class="notion-bookmark-link"><div class="notion-bookmark-link-icon"><img src="https://www.notion.so/image/https%3A%2F%2Fgithub.githubassets.com%2Ffavicon.ico?table=block&amp;id=8c0de4dd-63f3-401f-9550-d27010c93460&amp;t=8c0de4dd-63f3-401f-9550-d27010c93460" alt="GitHub Desktop" loading="lazy" decoding="async"/></div><div class="notion-bookmark-link-text">https://desktop.github.com/</div></div></div><div class="notion-bookmark-image"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fdesktop.github.com%2Fimages%2Fupgrade%2Fpr-checks.png?table=block&amp;id=8c0de4dd-63f3-401f-9550-d27010c93460&amp;t=8c0de4dd-63f3-401f-9550-d27010c93460" alt="GitHub Desktop" loading="lazy" decoding="async"/></div></a></div><div class="notion-text notion-block-1021426e956b48208b00327fc24c047c">点击Sign in to Github登录，或者skip this step 稍后登录都可以</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-942e70e16e2148da900d19d9b749b37d"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F88b0eacc-ed74-4580-a08a-aa729ec99fd6%2FUntitled.png?table=block&amp;id=942e70e1-6e21-48da-900d-19d9b749b37d&amp;t=942e70e1-6e21-48da-900d-19d9b749b37d&amp;width=2400&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></div></details><details class="notion-toggle notion-block-cdbabd5bca5a4bce8ba6586959e134ba"><summary>下载代码 </summary><div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-1d0412824c9140e196c933f68ba9ebe0"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F19bb5199-54eb-4742-9790-3894e89d2bde%2FUntitled.png?table=block&amp;id=1d041282-4c91-40e1-96c9-33f68ba9ebe0&amp;t=1d041282-4c91-40e1-96c9-33f68ba9ebe0&amp;width=1902&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-67f3ecbef0f8499184ce818b0c69b188">找到您的仓库地址进行Clone</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-534c0b090e244a0eb6bc96e8b49e2e19"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F6a75fbc1-3263-47c0-ad85-d7c36d98090c%2FUntitled.png?table=block&amp;id=534c0b09-0e24-4a0e-b6bc-96e8b49e2e19&amp;t=534c0b09-0e24-4a0e-b6bc-96e8b49e2e19&amp;width=1908&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-567eae70c5c74bf48021e40042edd077"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F0adecde9-a776-4bbf-a257-450b218b6f9f%2FUntitled.png?table=block&amp;id=567eae70-c5c7-4bf4-8021-e40042edd077&amp;t=567eae70-c5c7-4bf4-8021-e40042edd077&amp;width=1886&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-d5de0fb554694252b91cd7a073f4c3b8">点击Clone即可下载代码</div></div></details></ol></ol><ol start="2" class="notion-list notion-list-numbered notion-block-fe6dbdc020e04a58ab30ea8680fb4219" style="list-style-type:decimal"><li>用vscode打开项目</li><ol class="notion-list notion-list-numbered notion-block-fe6dbdc020e04a58ab30ea8680fb4219" style="list-style-type:lower-alpha"><details class="notion-toggle notion-block-747d6d122a7b4cee88893edf0e361447"><summary>打开项目文件</summary><div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-6636d48e81cc4ce7b7233dc164377031"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:528px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F4afb38e9-6e19-4608-aff8-7dedeb3628aa%2FUntitled.png?table=block&amp;id=6636d48e-81cc-4ce7-b723-3dc164377031&amp;t=6636d48e-81cc-4ce7-b723-3dc164377031&amp;width=528&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></div></details><details class="notion-toggle notion-block-f66ff20ab355423d8ea3da9eef42e96a"><summary>安装项目依赖的组件</summary><div><div class="notion-text notion-block-7a6db305c25e4e0ea1949690798a4bdd">点击 菜单栏的终端，并选择 新建终端，然后在新建的终端窗口中输入安装启动脚本：</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-cc885c641ad3457eae0ab50735115245"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2Fdc1d0ab6-1abc-4096-b188-aa8c9f7439ca%2FUntitled.png?table=block&amp;id=cc885c64-1ad3-457e-ae0a-b50735115245&amp;t=cc885c64-1ad3-457e-ae0a-b50735115245&amp;width=2438&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-b9061fbcc8bc4d3ba86dd4cb6781e36f">任选一种安装</div><div class="notion-callout notion-gray_background_co notion-block-11ba9233309144d6b1396bd35526966d"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text">静候片刻，首次安装依赖需要花一点时间</div></div></div></details><details class="notion-toggle notion-block-0113b2db8132440592be5abf39f9d7ae"><summary>启动项目 只需一个命令</summary><div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-d974150b469b4984aa69e3fe1d754846"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F0495c93c-688c-41d1-a6fb-7b03e55cbbf8%2FUntitled.png?table=block&amp;id=d974150b-469b-4984-aa69-e3fe1d754846&amp;t=d974150b-469b-4984-aa69-e3fe1d754846&amp;width=1454&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><details class="notion-toggle notion-block-6ccedde1293b4f25812f5be1faf90b94"><summary>其他脚本说明</summary><div></div></details></div></details></ol></ol><ol start="3" class="notion-list notion-list-numbered notion-block-1e87b63b97e849ff9663d9c0bb4738be" style="list-style-type:decimal"><li>访问页面</li><ol class="notion-list notion-list-numbered notion-block-1e87b63b97e849ff9663d9c0bb4738be" style="list-style-type:lower-alpha"><details class="notion-toggle notion-block-c134e83b6a9a408e8ba35a7bef99b978"><summary>浏览器打开 <a target="_blank" rel="noopener noreferrer" class="notion-link" href="http://localhost:3000/">http://localhost:3000/</a> 即可访问你的本地博客</summary><div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-628feceb70df44b282ff15d7a0a3db2f"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F2c2b2337-9c50-41d0-84be-a4675a4c4bfa%2FUntitled.png?table=block&amp;id=628feceb-70df-44b2-82ff-15d7a0a3db2f&amp;t=628feceb-70df-44b2-82ff-15d7a0a3db2f&amp;width=1666&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></div></details><div class="notion-callout notion-gray_background_co notion-block-2da28e0ef6874f3fa060ceacd81d9bb3"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text">调试模式下：代码的每次修改会实时影响到你的页面，不需要刷新或重启服务</div></div></ol></ol><div class="notion-blank notion-block-c085d0224fb544c9b5bbb767c0a1c35a"> </div></div></details><details class="notion-toggle notion-block-0f6dd16e896340d38ecdd0908fc46f03"><summary><h4 class="notion-h notion-h3 notion-h-indent-2 notion-block-0f6dd16e896340d38ecdd0908fc46f03" data-id="0f6dd16e896340d38ecdd0908fc46f03"><span><div id="0f6dd16e896340d38ecdd0908fc46f03" class="notion-header-anchor"></div><span class="notion-h-title">3.本地开发环境配置</span></span></h4></summary><div><div class="notion-text notion-block-9f3136f5040348be99fb86fd823fd675">VSCode中可以使用launch面板，进行设置环境变量以及断点调试</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-40fa41709b1a4a7d81890b7bc9974791"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:371.984375px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F079baae4-624a-4f86-bbf1-fec4327d3796%2FUntitled.png?table=block&amp;id=40fa4170-9b1a-4a7d-8189-0b7bc9974791&amp;t=40fa4170-9b1a-4a7d-8189-0b7bc9974791&amp;width=371.984375&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-7ec3904b992342b9bf40e0689c111a3c">创建一个launch文件</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-fe8f56e6ecdc482a9f46989134e4989f"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:480px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F8bed5f0c-26d9-48e5-9e35-696bcee5c00e%2FUntitled.png?table=block&amp;id=fe8f56e6-ecdc-482a-9f46-989134e4989f&amp;t=fe8f56e6-ecdc-482a-9f46-989134e4989f&amp;width=480&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><details class="notion-toggle notion-block-300f93b9208b805a806ce7a24024b624"><summary>可参考官方推荐配置</summary><div><div class="notion-text notion-block-322f93b9208b80bd991efc6177f8f492">VSCode 里会出现三个启动项：</div><h4 class="notion-h notion-h3 notion-block-322f93b9208b80578f86cac8309f1de1" data-id="322f93b9208b80578f86cac8309f1de1"><span><div id="322f93b9208b80578f86cac8309f1de1" class="notion-header-anchor"></div><a class="notion-hash-link" href="#322f93b9208b80578f86cac8309f1de1" title="① Debug Server"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">① Debug Server</span></span></h4><div class="notion-text notion-block-322f93b9208b80d6b246ffd4c0680197">只调试 Node 端</div><div class="notion-text notion-block-322f93b9208b8029a9b5fa6f04e75d55">适合调试：</div><ul class="notion-list notion-list-disc notion-block-322f93b9208b804da5f6c186f5db301b"><li><code class="notion-inline-code">getServerSideProps</code></li></ul><ul class="notion-list notion-list-disc notion-block-322f93b9208b8065873df62e7d7341b9"><li><code class="notion-inline-code">app/api/*</code></li></ul><ul class="notion-list notion-list-disc notion-block-322f93b9208b80ed9f70ed4452d571b4"><li><code class="notion-inline-code">middleware.ts</code></li></ul><ul class="notion-list notion-list-disc notion-block-322f93b9208b80d9acc8f42a5013489b"><li><code class="notion-inline-code">server components</code></li></ul><hr class="notion-hr notion-block-322f93b9208b80dc9b6dee61f484fd8d"/><h4 class="notion-h notion-h3 notion-block-322f93b9208b8094b463f9d5cf8a2960" data-id="322f93b9208b8094b463f9d5cf8a2960"><span><div id="322f93b9208b8094b463f9d5cf8a2960" class="notion-header-anchor"></div><a class="notion-hash-link" href="#322f93b9208b8094b463f9d5cf8a2960" title="② Debug Client (Chrome)"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">② Debug Client (Chrome)</span></span></h4><div class="notion-text notion-block-322f93b9208b80a2a806e505ebd79681">只启动浏览器调试</div><div class="notion-text notion-block-322f93b9208b80f6939dc5eb413febc2">适合调试：</div><ul class="notion-list notion-list-disc notion-block-322f93b9208b8086a546ddf3b5eb4421"><li>React组件</li></ul><ul class="notion-list notion-list-disc notion-block-322f93b9208b805ebf6bec5f5929d754"><li>hooks</li></ul><ul class="notion-list notion-list-disc notion-block-322f93b9208b80e89ec2ec3cf4d35d35"><li>前端逻辑</li></ul><ul class="notion-list notion-list-disc notion-block-322f93b9208b80bd94eff4cdc42f77dd"><li>页面跳转</li></ul><hr class="notion-hr notion-block-322f93b9208b8089a878c2bd3282d91e"/><h4 class="notion-h notion-h3 notion-block-322f93b9208b806a8e49f67062d5501c" data-id="322f93b9208b806a8e49f67062d5501c"><span><div id="322f93b9208b806a8e49f67062d5501c" class="notion-header-anchor"></div><a class="notion-hash-link" href="#322f93b9208b806a8e49f67062d5501c" title="③ Debug Full Stack（推荐）"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">③ Debug Full Stack（推荐）</span></span></h4><div class="notion-text notion-block-322f93b9208b803aa4e4fc0aba83f716">一次同时启动：</div><ul class="notion-list notion-list-disc notion-block-322f93b9208b809a8702effe619bec05"><li>Next dev server</li></ul><ul class="notion-list notion-list-disc notion-block-322f93b9208b80609053fd21576640ca"><li>Chrome调试</li></ul><div class="notion-text notion-block-322f93b9208b80268d0ac80e4e72211a">这是 <b>Next.js最常用调试方式</b>。</div></div></details><div class="notion-blank notion-block-300f93b9208b80e2be22fae361ef02e7"> </div><div class="notion-blank notion-block-d47d449eff0e4da88cbbac7d3f3cb7f1"> </div><div class="notion-blank notion-block-ff9e4cf89eaf484d92a20d9d6a2fa831"> </div></div></details><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-ec2753bdc1994c4fb01643c3c6a80b8c" data-id="ec2753bdc1994c4fb01643c3c6a80b8c"><span><div id="ec2753bdc1994c4fb01643c3c6a80b8c" class="notion-header-anchor"></div><a class="notion-hash-link" href="#ec2753bdc1994c4fb01643c3c6a80b8c" title="代码结构简介"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">代码结构简介</span></span></h2><h4 class="notion-h notion-h3 notion-h-indent-1 notion-block-a0c13734fa5845259beda35d4c5d017b" data-id="a0c13734fa5845259beda35d4c5d017b"><span><div id="a0c13734fa5845259beda35d4c5d017b" class="notion-header-anchor"></div><a class="notion-hash-link" href="#a0c13734fa5845259beda35d4c5d017b" title="NextJS"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">NextJS</span></span></h4><div class="notion-text notion-block-a8a9e6705faa47daadb45e5236e7200d">项目用NextJS框架构建，以下是代码所有主要目录，修改样式主要在<code class="notion-inline-code">themes</code> 目录下完成。</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-ac66811b38074440a16804ebb9ae8c80"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:528px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F0221eee6-b6fa-4968-a4c1-5021ad3844b1%2FUntitled.png?table=block&amp;id=ac66811b-3807-4440-a168-04ebb9ae8c80&amp;t=ac66811b-3807-4440-a168-04ebb9ae8c80&amp;width=528&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-callout notion-gray_background_co notion-block-9638c6b74bca44c5825f5572c05ae715"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text">关于NextJs框架请阅读官方文档获取帮助<div class="notion-row"><a target="_blank" rel="noopener noreferrer" class="notion-bookmark notion-block-843dbc3794254c2fa7157e67b5955bfa" href="https://www.nextjs.cn/docs/getting-started"><div><div class="notion-bookmark-title">快速入门 | Next.js</div><div class="notion-bookmark-description">欢迎阅读 Next.js 文档！ 如果你是初学 Next.js，我们建议你从 互动课程 开始。 通过这些带小测验的互动课程你将学到使用 Next.js 所需的全部知识。 如果你有任何与 Next.js 相关的问题，欢迎随时在 GitHub Discussions 上向我们的社区寻求帮助。 我们建议使用 create-next-app 创建新的 Next.js 应用程序，它会自动为你设置所有内容。创建项目，请运行： npx create-next-app@latest yarn create next-app 如果你希望使用 TypeScript 开发项目，可以通过 --typescript 参数创建 TypeScript 项目： npx create-next-app@latest --typescript yarn create next-app --typescript 安装完成后: 运行 npm run dev 或 yarn dev 来启动开发服务器，访问地址为 http://localhost:3000。</div><div class="notion-bookmark-link"><div class="notion-bookmark-link-icon"><img src="https://www.notion.so/image/https%3A%2F%2Fwww.nextjs.cn%2Fstatic%2Ffavicon%2Ffavicon.ico?table=block&amp;id=843dbc37-9425-4c2f-a715-7e67b5955bfa&amp;t=843dbc37-9425-4c2f-a715-7e67b5955bfa" alt="快速入门 | Next.js" loading="lazy" decoding="async"/></div><div class="notion-bookmark-link-text">https://www.nextjs.cn/docs/getting-started</div></div></div><div class="notion-bookmark-image"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fwww.nextjs.cn%2Fstatic%2Ftwitter-cards%2Fdocumentation.png?table=block&amp;id=843dbc37-9425-4c2f-a715-7e67b5955bfa&amp;t=843dbc37-9425-4c2f-a715-7e67b5955bfa" alt="快速入门 | Next.js" loading="lazy" decoding="async"/></div></a></div></div></div><h4 class="notion-h notion-h3 notion-h-indent-1 notion-block-c226ff44af554e3a8c1bde3bf2cc6b9e" data-id="c226ff44af554e3a8c1bde3bf2cc6b9e"><span><div id="c226ff44af554e3a8c1bde3bf2cc6b9e" class="notion-header-anchor"></div><a class="notion-hash-link" href="#c226ff44af554e3a8c1bde3bf2cc6b9e" title="TailWindCSS"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">TailWindCSS</span></span></h4><div class="notion-text notion-block-84c883d4f1a04742be30c136e461cea2">项目开发使用TailwindCss，这是一个极简、灵活的CSS工具库，上手后开发效率极高。</div><div class="notion-row"><a target="_blank" rel="noopener noreferrer" class="notion-bookmark notion-block-83dffa0534e543d988067a027315f721" href="https://juejin.cn/post/7053006266146717727"><div><div class="notion-bookmark-title">TailwindCSS为什么你要使用？</div><div class="notion-bookmark-description">TailwindCSS官方称一个可以让你脱离css文件，在html直接通过class修改样式的框架。 但是TailwindCSS一直受到CSS 方案备受争议。第一个问题就是这和写style css有什么区别？ 首先在我们的进行修改css样式的风法中，多多少少会用到一些4中方式 越往下走，颗粒度越来越大，约束性变高，自由性不足。而 TailwindCSS 位于第二层。 第一层的话，就很难复用了，所以 TailwindCSS 选择了第二层的原因。 在不久之前Facebook经过重构后的css体积已经重原来的413kb 压缩到74kb。 可是很多开发者，很疑惑。我的css文件下去了，但是我的html和组件的文件变得无比的大，并不知道这里的好处在哪里？ 首先第一，现在的开发模式已经是组件开发了，就算你在搞一个css来维护。其实很多的样式属性这个组件有，那个组件也存在复用。这个没有必要，这里的自己的组件样式交给组件自己维护就好了。 第二点就是想到这个疑惑的，估计是没有去了解过nginx的gzip。只是知道有这么一回事。 gzip 的核心Deflate使用的是LZ77 算法和 Huffman 编码来压缩文件，重复度越高的文件可压缩的空间就越大。 即使 HTML 因为类名过多造成体积增大，由于 class 高度相似，gzip 也将会得到一个很大的压缩比例。 这才是 TailwindCSS 想要的结果 第一次我使用 tailwind ui 框架的时候，很多情况看多以下的这种写法。 你想要多少的数值，直接写多少就好了。 还有对应响应式 对应你使用的@media，你感觉谁更加舒服呢？ 第三 就是后期维护的时候，就算有人跑路了，这么多个css，后面的人只需要去看html就能维护。这么多的css file你慢慢找吧，反正我是不想找的。 第四 Jit css编译，使用TailwindCSS在编译的过程中，比css-loader less-loader 都要快 说了这么这些好处，TailwindCSS有什么不足呢？我说说我的看法吧。 第一遇到复杂一点的css操作你不能直接使用 TailwindCSS 操作 比如以上的情况，你需要写css来操作子元素的显示，除非你无聊非要用js来写，也不是不行。 第二是增加了记忆负担，它的命名和你认知中的使用不一样，前期需要一直查阅文档，或者下载TailwindCSS的提示插件。要不你无从下手。 但是一旦你有习惯了，形成条件反射，那就是另一种情况，你会直喊香。 如果你正在做代码加速优化的话，你可以试试TailwindCSS.因为gzip后是真的小。 如果你是一个爱折腾的人，可是试试TailwindCSS。 如果你感觉你的组件已经可以完全独立使用一个css的时候，可以使用TailwindCSS来制作这个组件。后面要改代码时候，只需要去这个组件修改，并且不用担心自己的class会影响到他人的组件。</div><div class="notion-bookmark-link"><div class="notion-bookmark-link-icon"><img src="https://www.notion.so/image/https%3A%2F%2Flf3-cdn-tos.bytescm.com%2Fobj%2Fstatic%2Fxitu_juejin_web%2F%2Fstatic%2Ffavicons%2Ffavicon-16x16.png?table=block&amp;id=83dffa05-34e5-43d9-8806-7a027315f721&amp;t=83dffa05-34e5-43d9-8806-7a027315f721" alt="TailwindCSS为什么你要使用？" loading="lazy" decoding="async"/></div><div class="notion-bookmark-link-text">https://juejin.cn/post/7053006266146717727</div></div></div><div class="notion-bookmark-image"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Flf3-cdn-tos.bytescm.com%2Fobj%2Fstatic%2Fxitu_juejin_web%2Fimg%2Flv-4.a78c420.png?table=block&amp;id=83dffa05-34e5-43d9-8806-7a027315f721&amp;t=83dffa05-34e5-43d9-8806-7a027315f721" alt="TailwindCSS为什么你要使用？" loading="lazy" decoding="async"/></div></a></div><div class="notion-row"><a target="_blank" rel="noopener noreferrer" class="notion-bookmark notion-block-f5e7b93c18d8457aa27049b2fe10d46a" href="https://www.tailwindcss.cn/docs/installation"><div><div class="notion-bookmark-title">安装 - TailwindCSS中文文档 | TailwindCSS中文网</div><div class="notion-bookmark-description">The simplest and fastest way to get up and running with Tailwind CSS from scratch is with the Tailwind CLI tool.</div><div class="notion-bookmark-link"><div class="notion-bookmark-link-icon"><img src="https://www.notion.so/image/https%3A%2F%2Fwww.tailwindcss.cn%2Ffavicons%2Fapple-touch-icon.png%3Fv%3D3?table=block&amp;id=f5e7b93c-18d8-457a-a270-49b2fe10d46a&amp;t=f5e7b93c-18d8-457a-a270-49b2fe10d46a" alt="安装 - TailwindCSS中文文档 | TailwindCSS中文网" loading="lazy" decoding="async"/></div><div class="notion-bookmark-link-text">https://www.tailwindcss.cn/docs/installation</div></div></div><div class="notion-bookmark-image"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Ftailwindcss.com%2Fapi%2Fog%3Fpath%3D%2Fdocs%2Finstallation?table=block&amp;id=f5e7b93c-18d8-457a-a270-49b2fe10d46a&amp;t=f5e7b93c-18d8-457a-a270-49b2fe10d46a" alt="安装 - TailwindCSS中文文档 | TailwindCSS中文网" loading="lazy" decoding="async"/></div></a></div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-cace0bf7ab564c2ea0da4fce8dec93d4" data-id="cace0bf7ab564c2ea0da4fce8dec93d4"><span><div id="cace0bf7ab564c2ea0da4fce8dec93d4" class="notion-header-anchor"></div><a class="notion-hash-link" href="#cace0bf7ab564c2ea0da4fce8dec93d4" title="代码格式规范"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">代码格式规范</span></span></h2><div class="notion-text notion-block-1ac91ebd7eab44639ca428f506f88f33">使用Eslint + Prettier，关于格式化代码，可以阅读这篇文档：</div><div class="notion-row"><a target="_blank" rel="noopener noreferrer" class="notion-bookmark notion-block-94cf2ab0ce824cbc80c3082102cf04ff" href="https://juejin.cn/post/7156893291726782500"><div><div class="notion-bookmark-title">juejin.cn</div><div class="notion-bookmark-link"><div class="notion-bookmark-link-text">https://juejin.cn/post/7156893291726782500</div></div></div></a></div><ul class="notion-list notion-list-disc notion-block-615f7886cfc24d75835d15e7e0313286"><li>ESLint插件：</li><ul class="notion-list notion-list-disc notion-block-615f7886cfc24d75835d15e7e0313286"><li><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://marketplace.visualstudio.com/items?itemName=dbaeumer.vscode-eslint">https://marketplace.visualstudio.com/items?itemName=dbaeumer.vscode-eslint</a></li><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-193698ff8ac0443098aedd24d6679e9d"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:576px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F5c32c4f2-3e88-4a96-8dd2-ed25e6d03280%2FUntitled.png?table=block&amp;id=193698ff-8ac0-4430-98ae-dd24d6679e9d&amp;t=193698ff-8ac0-4430-98ae-dd24d6679e9d&amp;width=576&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ul></ul><ul class="notion-list notion-list-disc notion-block-cb4ccea15aff4b2f937c5858ba643360"><li>Prettier插件</li><ul class="notion-list notion-list-disc notion-block-cb4ccea15aff4b2f937c5858ba643360"><div class="notion-text notion-block-79d71ed7acfe4a0eadaba543d662e211">有两个插件任选一种,按照插件内的配置说明配置您的工作空间即可。</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-28bd1f3358cb4d5fa3de8130ff40e3a4"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:576px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2Fb98c6f03-1f00-4f0c-94e9-baf7ae21b21a%2FUntitled.png?table=block&amp;id=28bd1f33-58cb-4d5f-a3de-8130ff40e3a4&amp;t=28bd1f33-58cb-4d5f-a3de-8130ff40e3a4&amp;width=576&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><details class="notion-toggle notion-block-db8b066c0546437683fe9dc23d54ada8"><summary>示例：Prettier - Code formatter</summary><div><div class="notion-text notion-block-da58011ed0614016b9c04f3cb580cc8c">使用说明</div><ul class="notion-list notion-list-disc notion-block-d6ff3acf57804c8babd96913b2c8f0d9"><li> <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://marketplace.visualstudio.com/items?itemName=esbenp.prettier-vscode">https://marketplace.visualstudio.com/items?itemName=esbenp.prettier-vscode</a></li></ul><div class="notion-text notion-block-ed01cd411066429fbeeea6ee0fa0de57">安装后，在项目配置中启用自动格式化，在settings.json中添加如下配置：</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-227bd3b8abd34bd39da32aac07e5c079"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F414226bc-04b6-4319-b6bc-baa68ce6aa09%2FUntitled.png?table=block&amp;id=227bd3b8-abd3-4bd3-9da3-2aac07e5c079&amp;t=227bd3b8-abd3-4bd3-9da3-2aac07e5c079&amp;width=547&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-6fe597f5c03246a28ccaccd3d55d4a46">安装后，在项目配置中启用自动格式化，在用户，或者项目的settings.json中添加如下配置：</div></div></details><details class="notion-toggle notion-block-eb962934965d4c1c924b0eb3194b5a4e"><summary>示例二：Prettier - Eslint</summary><div><ul class="notion-list notion-list-disc notion-block-c26e88fa578c4bce9cff79bc16cb72bb"><li>使用说明: <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://marketplace.visualstudio.com/items?itemName=rvest.vs-code-prettier-eslint">Prettier ESLint - Visual Studio Marketplace</a></li></ul><ul class="notion-list notion-list-disc notion-block-694e4652c6554d9abbaaf56655987190"><li>安装后，在项目配置中启用自动格式化，在settings.json中添加如下配置：</li><ul class="notion-list notion-list-disc notion-block-694e4652c6554d9abbaaf56655987190"></ul></ul></div></details></ul></ul><ul class="notion-list notion-list-disc notion-block-1dd6f9ebb80b410a9b75d3408a767860"><li>项目中的相关配置文件参考。</li><ul class="notion-list notion-list-disc notion-block-1dd6f9ebb80b410a9b75d3408a767860"></ul></ul></main></div>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[公众号解锁文章]]></title>
            <link>https://docs.tangly1024.com/article/wechat-offical-account</link>
            <guid>https://docs.tangly1024.com/article/wechat-offical-account</guid>
            <pubDate>Thu, 05 Sep 2024 00:00:00 GMT</pubDate>
            <content:encoded><![CDATA[<div id="notion-article" class="mx-auto overflow-hidden "><main class="notion light-mode notion-page notion-block-aadeb849777d4283b3013eec0d7314ee"><div class="notion-viewport"></div><div class="notion-collection-page-properties"></div><div class="notion-callout notion-brown_background_co notion-block-311f93b9208b8012b4c6cfc1aa55bdcb"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="⚠️">⚠️</span></div><div class="notion-callout-text"><div class="notion-text notion-block-311f93b9208b8020937ffb8ea66f429d">OpenWrite停止此项服务，公众号引流的方案失效了，因此以下文章内容已过期。</div></div></div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-75a09026065d49a08b8859c90e310fa6" data-id="75a09026065d49a08b8859c90e310fa6"><span><div id="75a09026065d49a08b8859c90e310fa6" class="notion-header-anchor"></div><a class="notion-hash-link" href="#75a09026065d49a08b8859c90e310fa6" title="如何解锁"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">如何解锁</span></span></h2><div class="notion-text notion-block-cd12fda55e1f4ee08eb67da3ba783238">在阅读文章详情时，默认会隐藏掉一半的文章内容，后半段需要解锁观看。</div><ol start="1" class="notion-list notion-list-numbered notion-block-16bf93b9208b8063a9e7c49fb0c96911" style="list-style-type:decimal"><li>点击文章底部的“原创不易，完成人机验证，阅读全文“</li><ol class="notion-list notion-list-numbered notion-block-16bf93b9208b8063a9e7c49fb0c96911" style="list-style-type:lower-alpha"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-cdbf6089d1d44b99b393802c8ce33b83"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:288px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2Fb0277f18-ad26-4985-890d-78742ef4925b%2Fimage.png?table=block&amp;id=cdbf6089-d1d4-4b99-b393-802c8ce33b83&amp;t=cdbf6089-d1d4-4b99-b393-802c8ce33b83&amp;width=288&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ol></ol><ol start="2" class="notion-list notion-list-numbered notion-block-16bf93b9208b8008ba0edf0507a62cd3" style="list-style-type:decimal"><li>在弹出的对话框中，可以看到引导提示：在微信中搜索公众号名，或扫码关注公众号</li><ol class="notion-list notion-list-numbered notion-block-16bf93b9208b8008ba0edf0507a62cd3" style="list-style-type:lower-alpha"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-a1ff190ca1614f02ba9c5de176c1d44a"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:288px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F5da33c5a-3cdf-468a-86ae-b3bd0afd14c2%2Fimage.png?table=block&amp;id=a1ff190c-a161-4f02-ba9c-5de176c1d44a&amp;t=a1ff190c-a161-4f02-ba9c-5de176c1d44a&amp;width=288&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ol></ol><ol start="3" class="notion-list notion-list-numbered notion-block-16bf93b9208b80be84dac69dbf0b1cb7" style="list-style-type:decimal"><li>在公众号，点击左下角“验证码”；（或直接在聊天框发送“验证码”）。</li><ol class="notion-list notion-list-numbered notion-block-16bf93b9208b80be84dac69dbf0b1cb7" style="list-style-type:lower-alpha"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-16bf93b9208b80cb8dd1cf105e38afd3"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:288px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F998c07b1-caca-4cc7-8d2c-2a7529706a0a%2Fimage.png?table=block&amp;id=16bf93b9-208b-80cb-8dd1-cf105e38afd3&amp;t=16bf93b9-208b-80cb-8dd1-cf105e38afd3&amp;width=288&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-16bf93b9208b80caace4c65895f0e348">公众号会推送一个链接，访问链接即可看到验证码</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-16bf93b9208b804a973fdba50bb9fc09"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:288px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F66bc0c90-e6be-4142-9a57-1d774b57831c%2Fimage.png?table=block&amp;id=16bf93b9-208b-804a-973f-dba50bb9fc09&amp;t=16bf93b9-208b-804a-973f-dba50bb9fc09&amp;width=288&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ol></ol><ol start="4" class="notion-list notion-list-numbered notion-block-16bf93b9208b805b887ace5994456917" style="list-style-type:decimal"><li>回到网页中输入验证码，并点击提交即可</li><ol class="notion-list notion-list-numbered notion-block-16bf93b9208b805b887ace5994456917" style="list-style-type:lower-alpha"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-16bf93b9208b804ba1c8c37e5a432e3d"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:288px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2Fc8bbe22f-9a9e-4cea-81aa-e8c59e8ecdd1%2Fimage.png?table=block&amp;id=16bf93b9-208b-804b-a1c8-c37e5a432e3d&amp;t=16bf93b9-208b-804b-a1c8-c37e5a432e3d&amp;width=288&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ol></ol><div class="notion-blank notion-block-16bf93b9208b80698240cd9a02bb2587"> </div><div class="notion-callout notion-gray_background_co notion-block-1bb6c802f3da407a889b28a3441836b3"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text"><ul class="notion-list notion-list-disc notion-block-1a32aee64ad04b1f9ee7d74ec1e899de"><li>目前已支持所有主题，验证码只需要输入一次，即可解锁全站访问。</li></ul><ul class="notion-list notion-list-disc notion-block-16bf93b9208b809cb429fa3fe13c277a"><li>需要更新到4.7.0的版本之后才支持本功能。</li></ul></div></div><div class="notion-callout notion-gray_background_co notion-block-cb12a57751f7477ea0398a2f87a3dac4"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text"><div class="notion-text notion-block-dc74e7392e37439d909f01ed9dca06a3">本功能由<a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://www.helloxiaobai.cn/about">自动驾驶小白说</a>倾情赞助。</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-a4b949e29a0c4e639d5e2c9f1fd5d35f"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:144px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2Fc0675404-a4cf-4cb7-8821-8b749c4fa7c7%2F9a9d5135-ccdb-4c3e-aa57-4912b75d87a6.png?table=block&amp;id=a4b949e2-9a0c-4e63-9d5e-2c9f1fd5d35f&amp;t=a4b949e2-9a0c-4e63-9d5e-2c9f1fd5d35f&amp;width=144&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-e4a4f4e884264971bd89069c2c3ef3f5"><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://www.helloxiaobai.cn/about">自动驾驶小白说</a>, 输出专业自动驾驶算法教程的开发者社区. 🦈</div></div></div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-121ec81426bc46f69ebc7094c4bf753b" data-id="121ec81426bc46f69ebc7094c4bf753b"><span><div id="121ec81426bc46f69ebc7094c4bf753b" class="notion-header-anchor"></div><a class="notion-hash-link" href="#121ec81426bc46f69ebc7094c4bf753b" title="NotionNext配置说明"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">NotionNext配置说明</span></span></h2><div class="notion-callout notion-gray_background_co notion-block-180f93b9208b80a18802e4cdee5da308"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text"><div class="notion-text notion-block-3c0c798756014b0e8cd1c43eaa05a66d">在2025-01-19的版本后加入了黄名单配置，设置后只锁定部分文章</div></div></div><div class="notion-text notion-block-72113cd46c2f47ffa336ac54a83969db">在您的Notion配置中心添加以下配置，即可在网页上激活文章验证码解锁功能</div><table class="notion-simple-table notion-block-96ac9709608a4e869084e340f1b10d20"><tbody><tr class="notion-simple-table-row notion-block-eeec922a6d544602b45fa8c4adf0ff5a"><td class="" style="width:239.234375px"><div class="notion-simple-table-cell">配置名</div></td><td class="" style="width:193.765625px"><div class="notion-simple-table-cell">配置值（示例）</div></td><td class="" style="width:232px"><div class="notion-simple-table-cell">说明</div></td></tr><tr class="notion-simple-table-row notion-block-924aa977f6fb44edb06a8e44cda2c4eb"><td class="" style="width:239.234375px"><div class="notion-simple-table-cell">OPEN_WRITE_BLOG_ID</div></td><td class="" style="width:193.765625px"><div class="notion-simple-table-cell">3xxxx-1xxxxxxxxxx0-xx4</div></td><td class="" style="width:232px"><div class="notion-simple-table-cell">OpenWrite后台配置的博客ID[<code class="notion-inline-code"><b>blogId</b></code>]</div></td></tr><tr class="notion-simple-table-row notion-block-c23fc7eb332f4018aef6597a2ef51dfc"><td class="" style="width:239.234375px"><div class="notion-simple-table-cell">OPEN_WRITE_QRCODE</div></td><td class="" style="width:193.765625px"><div class="notion-simple-table-cell"><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://open.weixin.qq.com/qr/code?username=gh_29d5e8d7d648">https://open.weixin.qq.com/qr/code?username=gh_29d5e8d7d648</a></div></td><td class="" style="width:232px"><div class="notion-simple-table-cell">公众号二维码图片</div></td></tr><tr class="notion-simple-table-row notion-block-b491a37e0ec04d36ae42e9916c3f0080"><td class="" style="width:239.234375px"><div class="notion-simple-table-cell">OPEN_WRITE_NAME</div></td><td class="" style="width:193.765625px"><div class="notion-simple-table-cell">tangly1024</div></td><td class="" style="width:232px"><div class="notion-simple-table-cell">公众号名字，可用于搜索关注</div></td></tr><tr class="notion-simple-table-row notion-block-dd9c114b413a4c069bd84fa9437743a3"><td class="" style="width:239.234375px"><div class="notion-simple-table-cell">OPEN_WRITE_KEYWORD</div></td><td class="" style="width:193.765625px"><div class="notion-simple-table-cell">验证码</div></td><td class="" style="width:232px"><div class="notion-simple-table-cell">在公众号设置的自动关键词</div></td></tr><tr class="notion-simple-table-row notion-block-047a3d95644a41a6be07215662fdb7ff"><td class="" style="width:239.234375px"><div class="notion-simple-table-cell">OPEN_WRITE_BTN_TEXT</div></td><td class="" style="width:193.765625px"><div class="notion-simple-table-cell">原创不易，完成人机检测，阅读全文</div></td><td class="" style="width:232px"><div class="notion-simple-table-cell">【非必填】按钮提示词</div></td></tr><tr class="notion-simple-table-row notion-block-43b07f330bf14d50b132d156a2bf4eb2"><td class="" style="width:239.234375px"><div class="notion-simple-table-cell">OPEN_WRITE_WHITE_LIST</div></td><td class="" style="width:193.765625px"><div class="notion-simple-table-cell">about,example,test</div></td><td class="" style="width:232px"><div class="notion-simple-table-cell">【非必填】白名单，不需要加密的文章slug，英文逗号隔开。全站其余文章都需要验证码。如果只需要个别文章上锁，请使用黄名单功能</div></td></tr><tr class="notion-simple-table-row notion-block-180f93b9208b80539bcadfdbc477a80f"><td class="" style="width:239.234375px"><div class="notion-simple-table-cell">OPEN_WRITE_YELLOW_LIST</div></td><td class="" style="width:193.765625px"><div class="notion-simple-table-cell">wechat-offical-account</div></td><td class="" style="width:232px"><div class="notion-simple-table-cell">【非必填】黄名单，优先级最高，开启后只会锁定黄名单中的文章.英文逗号隔开多个。</div></td></tr><tr class="notion-simple-table-row notion-block-2fbe0830b9a148399ab4d50082c70495"><td class="" style="width:239.234375px"><div class="notion-simple-table-cell">OPEN_WRITE_VALIDITY_DURATION</div></td><td class="" style="width:193.765625px"><div class="notion-simple-table-cell">1</div></td><td class="" style="width:232px"><div class="notion-simple-table-cell">【非必填】验证一次后，阅读权限的持续时长，单位是“小时”，默认是1小时</div></td></tr></tbody></table><div class="notion-text notion-block-405fbde9c7fe4e09a785e34fd526586e">要实现这个配置，你需要先注册OpenWrite平台，获取blogId，并且设置一个用于回复的关键词绑定。</div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-b35459ef7eeb4c268fffeba4b403c80a" data-id="b35459ef7eeb4c268fffeba4b403c80a"><span><div id="b35459ef7eeb4c268fffeba4b403c80a" class="notion-header-anchor"></div><a class="notion-hash-link" href="#b35459ef7eeb4c268fffeba4b403c80a" title="配置的ID从哪里来"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">配置的ID从哪里来</span></span></h2><ol start="1" class="notion-list notion-list-numbered notion-block-72329d50e2a844aea899322965550708" style="list-style-type:decimal"><li>进入 Open Write 页面：</li><ol class="notion-list notion-list-numbered notion-block-72329d50e2a844aea899322965550708" style="list-style-type:lower-alpha"><ul class="notion-list notion-list-disc notion-block-53dd7f6c0b414ad4b6e2d417cd4a3b00"><li>注册：<b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="http://admin.openwrite.cn/">http://admin.openwrite.cn/</a></b></li></ul><ul class="notion-list notion-list-disc notion-block-8f10e8ca2de848668a73290de92cc8a6"><li>登录：<b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://readmore.openwrite.cn/login">https://readmore.openwrite.cn/login</a></b></li></ul></ol></ol><ol start="2" class="notion-list notion-list-numbered notion-block-cab0c447d641470fa0e792d684e314a4" style="list-style-type:decimal"><li>「配置页面」-&gt;「添加博客」</li><ol class="notion-list notion-list-numbered notion-block-cab0c447d641470fa0e792d684e314a4" style="list-style-type:lower-alpha"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-d98a95cd6139499095a624d99c8a91d4"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F192363c9-0fb0-4fcb-96cd-aecc18ecd7cc%2Freadmore-1.png?table=block&amp;id=d98a95cd-6139-4990-95a6-24d99c8a91d4&amp;t=d98a95cd-6139-4990-95a6-24d99c8a91d4&amp;width=680.0000610351562&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ol></ol><ol start="3" class="notion-list notion-list-numbered notion-block-c78067da93da4667b2cc3d6e031b1e7d" style="list-style-type:decimal"><li>根据提示填写你的信息，之后就会生成整合方案</li><ol class="notion-list notion-list-numbered notion-block-c78067da93da4667b2cc3d6e031b1e7d" style="list-style-type:lower-alpha"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-6326d08f23134d02884a34ee21089697"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F8409bdec-1792-431b-9704-98c951ac0a74%2Freadmore-4.png?table=block&amp;id=6326d08f-2313-4d02-884a-34ee21089697&amp;t=6326d08f-2313-4d02-884a-34ee21089697&amp;width=680.0000610351562&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ol></ol><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-dbfb3b8781d2401c801a2dcbcf477880" data-id="dbfb3b8781d2401c801a2dcbcf477880"><span><div id="dbfb3b8781d2401c801a2dcbcf477880" class="notion-header-anchor"></div><a class="notion-hash-link" href="#dbfb3b8781d2401c801a2dcbcf477880" title="关键步骤"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">关键步骤</span></span></h3><ol start="1" class="notion-list notion-list-numbered notion-block-5db5c5456c5a475daef7f88c4456df7e" style="list-style-type:decimal"><li>我们需要记录这里的<code class="notion-inline-code">blogId</code>这个参数，即上图中<code class="notion-inline-code">blogId</code>后面<code class="notion-inline-code">打马赛克</code>的部分。</li></ol><ol start="2" class="notion-list notion-list-numbered notion-block-3adf83082f574be894d3d08bc0a5a744" style="list-style-type:decimal"><li>按照提示需要在公众号后台设置<b>关键词回复</b>。</li></ol><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-591835706851444d98770721ab196984" data-id="591835706851444d98770721ab196984"><span><div id="591835706851444d98770721ab196984" class="notion-header-anchor"></div><a class="notion-hash-link" href="#591835706851444d98770721ab196984" title="公众号二维码图片哪里来？"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">公众号二维码图片哪里来？</span></span></h2><ol start="1" class="notion-list notion-list-numbered notion-block-e5dc2671129f46e99516f49bcd260407" style="list-style-type:decimal"><li>在<b>公众号</b>管理中心，找到并点击“设置”，找到“账号信息”</li></ol><ol start="2" class="notion-list notion-list-numbered notion-block-31f9e069f1bd4f728638db8608c2650b" style="list-style-type:decimal"><li>在账号信息页面，找到“<b>二维码</b>”，然后点击“更多尺寸”</li></ol><ol start="3" class="notion-list notion-list-numbered notion-block-eb32d6d8131544e793adbf9e5238cdcd" style="list-style-type:decimal"><li>进入更多尺寸的页面，会呈现出常用的<b>二维码</b>尺寸，和建议扫描的距离，根据需要，选择下载，即可获得相应的<b>公众号二维码</b>。</li></ol><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-f8ee23ea38b8422480bbb26e437bb2d6" data-id="f8ee23ea38b8422480bbb26e437bb2d6"><span><div id="f8ee23ea38b8422480bbb26e437bb2d6" class="notion-header-anchor"></div><a class="notion-hash-link" href="#f8ee23ea38b8422480bbb26e437bb2d6" title="公众号关键词回复如何设置？"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">公众号关键词回复如何设置？</span></span></h2><div class="notion-text notion-block-6466c29613c34232b1328e2498865ab5">公众号后台找到 ： 自动回复→关键词回复→添加回复</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-09d9de36ad0d4e28ab8f930ae95802e8"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2Fcc6580b0-9949-4d14-91ee-af041a228188%2Fimage.png?table=block&amp;id=09d9de36-ad0d-4e28-ab8f-930ae95802e8&amp;t=09d9de36-ad0d-4e28-ab8f-930ae95802e8&amp;width=707.9861450195312&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-ddac904c1d4d4073ac6c3a3ad900875b">参考我的配置如下：</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-08ae4789b9064048aec0cf2cac3d60d1"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2Fd2a401bf-afae-4730-b2a4-bd53c4204893%2Fimage.png?table=block&amp;id=08ae4789-b906-4048-aec0-cf2cac3d60d1&amp;t=08ae4789-b906-4048-aec0-cf2cac3d60d1&amp;width=707.9861450195312&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-callout notion-blue_background_co notion-block-140f93b9208b80e2a91ff41f50993f4d"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text"><div class="notion-text notion-block-305b90bd516941a5ad197777a2807b55">自动回复的内容中，最重要的就是要带上Openwrite后台提供的验证码链接，用户点击此链接后可以获得验证码，示例：

<b>&lt;a href=&quot;https://readmore.openwrite.cn/code/generate?</b><span class="notion-red"><b>blogId</b></span><b>=</b><span class="notion-red"><b>xxxxx</b></span><b>&quot;&gt;点此链接，获取博客解锁验证码&lt;/a&gt;
</b></div><div class="notion-text notion-block-140f93b9208b80f98713fce1f07dbea6">注意，这里每个人的链接是不同的，特别是blogId这个参数。
</div></div></div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-a07289f29ba9435e9bd74d20e2813882" data-id="a07289f29ba9435e9bd74d20e2813882"><span><div id="a07289f29ba9435e9bd74d20e2813882" class="notion-header-anchor"></div><a class="notion-hash-link" href="#a07289f29ba9435e9bd74d20e2813882" title="参考"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">参考</span></span></h2><div class="notion-text notion-block-3eba27d3634d418191166965e1385f0f">OpenWrite官方文档：</div><div class="notion-row"><a target="_blank" rel="noopener noreferrer" class="notion-bookmark notion-block-07f2186165554b56be4cc329ec0def8e" href="https://openwrite.cn/guide/readmore/readmore.html"><div><div class="notion-bookmark-title">博客导流公众号</div><div class="notion-bookmark-description">做最懂自媒体的工具平台</div><div class="notion-bookmark-link"><div class="notion-bookmark-link-icon"><img src="https://www.notion.so/image/https%3A%2F%2Fopenwrite.cn%2Ffavicon.ico?table=block&amp;id=07f21861-6555-4b56-be4c-c329ec0def8e&amp;t=07f21861-6555-4b56-be4c-c329ec0def8e" alt="博客导流公众号" loading="lazy" decoding="async"/></div><div class="notion-bookmark-link-text">https://openwrite.cn/guide/readmore/readmore.html</div></div></div></a></div><div class="notion-blank notion-block-2d22a358c13a474e89a85e44881bc814"> </div></main></div>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Vercel绑定自定义域名]]></title>
            <link>https://docs.tangly1024.com/article/vercel-domain</link>
            <guid>https://docs.tangly1024.com/article/vercel-domain</guid>
            <pubDate>Thu, 17 Feb 2022 00:00:00 GMT</pubDate>
            <description><![CDATA[Vercel 借助cloudFlare可以快速绑定解析自己的域名]]></description>
            <content:encoded><![CDATA[<div id="notion-article" class="mx-auto overflow-hidden "><main class="notion light-mode notion-page notion-block-1668f039d2e04630809c28c8cd459f24"><div class="notion-viewport"></div><div class="notion-collection-page-properties"></div><div class="notion-callout notion-gray_background_co notion-block-5f6009a21f424e1383ff9932c2880132"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="❓">❓</span></div><div class="notion-callout-text">为什么要绑定自定义域名？

vercel默认提供的域名 *.vercel.app 由于滥用已被大陆屏蔽（DNS污染），如果需要在国内能访问到您的站点，请绑定一个新的域名即可</div></div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-5b8acbfdd4d04a0d9539ab64a39b7619" data-id="5b8acbfdd4d04a0d9539ab64a39b7619"><span><div id="5b8acbfdd4d04a0d9539ab64a39b7619" class="notion-header-anchor"></div><a class="notion-hash-link" href="#5b8acbfdd4d04a0d9539ab64a39b7619" title="准备一个域名"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">准备一个域名</span></span></h2><div class="notion-text notion-block-3d19a061c9d74927bf0e5e4d6ae050c1">首先购买自己的域名，您可以选择以下渠道进行购买：</div><ul class="notion-list notion-list-disc notion-block-a9f0f836ad45442e9910d333d57d24b0"><li><a target="_blank" rel="noopener noreferrer" class="notion-link" href="http://www.namesilo.com/?rid=fe5a225yc">Namesilo</a></li></ul><ul class="notion-list notion-list-disc notion-block-2651f927ce3b43a6b248ae471820efb5"><li><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://www.godaddy.com/zh-sg/offers/godaddy">Godaddy</a></li></ul><div class="notion-text notion-block-cee510cd7ff246dc991b4dbac8606ba7">另外您还可以选择从以下平台获取到免费的域名：</div><ul class="notion-list notion-list-disc notion-block-8ed2bbd55a4d455d9d3385a1dd1c9dd8"><li><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://zhuanlan.zhihu.com/p/538005306">eu.org</a> （eu.org是欧盟组织的免费域名；需要英国的用户信息才能注册;）</li></ul><ul class="notion-list notion-list-disc notion-block-fa9d521bd87542b88a4a099bae6d4422"><li><s><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://freenom.com">Freenom</a></s><s> （目前已逐步停止域名服务）</s></li></ul><h4 class="notion-h notion-h3 notion-h-indent-1 notion-block-ea9c525748914d5489ab14796a4c2d10" data-id="ea9c525748914d5489ab14796a4c2d10"><span><div id="ea9c525748914d5489ab14796a4c2d10" class="notion-header-anchor"></div><a class="notion-hash-link" href="#ea9c525748914d5489ab14796a4c2d10" title="首推Namesilo"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">首推Namesilo</span></span></h4><div class="notion-text notion-block-d68193154112482a8ab064a23035732a">我早先在腾讯云购买的域名，但奈何无耻的价格套路，最后选择迁入<a target="_blank" rel="noopener noreferrer" class="notion-link" href="http://www.namesilo.com/?rid=fe5a225yc">Namesilo</a>。</div><div class="notion-callout notion-gray_background_co notion-block-0b06fb44399e44129332a7529b411a7b"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text"><b>套路</b>指那些首年极其便宜，但次年续费很贵的。如 Godaddy，首年 $0.99，次年续费要 102 元人民币，而且隐私保护还需要额外再加 60 元。</div></div><div class="notion-text notion-block-ded3a6dc29bc442cab501ee14b359488">NameSilo优点：</div><ul class="notion-list notion-list-disc notion-block-5030568d4655407c845a2c910964a1ad"><li><b>价格便宜稳定，无套路</b></li><ul class="notion-list notion-list-disc notion-block-5030568d4655407c845a2c910964a1ad"><div class="notion-text notion-block-4f2c66cdd4554ec98bd1caaa240e5d62">Namesilo 域名本身价格就比较便宜，COM 域名 $8.99/年，除了一个一美元优惠码，基本没有其他大幅度促销活动，域名续费和首年购买价格一致。</div><div class="notion-text notion-block-2f18a563beda46cd833287069037e343">Namesilo 价格表：<a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://www.namesilo.com/pricing.php?rid=fe5a225yc">Domain Pricing</a></div><div class="notion-callout notion-gray_background_co notion-block-f2d4f4275e2b4e0c990997071fade767"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text">填入我的优惠码 <code class="notion-inline-code">tangly1024a</code> <b> </b>可以享受 <code class="notion-inline-code"><b>1$</b></code>的 优惠。<figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-38e0ed5c78664db3b85ea6ac37f795eb"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F34066f41-e1bc-4ad5-b36e-d3ad84cb5106%2FUntitled.png?table=block&amp;id=38e0ed5c-7866-4db3-b85e-a6ac37f795eb&amp;t=38e0ed5c-7866-4db3-b85e-a6ac37f795eb&amp;width=620.0173950195312&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></div></div><div class="notion-blank notion-block-123f93b9208b8005b065f794bcf946e9"> </div></ul></ul><ul class="notion-list notion-list-disc notion-block-3eba34cc1d19431b9bf9dd0b55e0b50e"><li><b>永久免费的隐私保护</b></li><ul class="notion-list notion-list-disc notion-block-3eba34cc1d19431b9bf9dd0b55e0b50e"><div class="notion-text notion-block-3c468e426ed5488f95c77f4ccf705d0e">Namesilo 提供永久免费的域名隐私保护，防止别人通过 WHOIS 查询获取域名所有者的个人注册信息。作为对比，Godaddy 的隐私保护是 60 元/年，Namecheap 则是免费提供第一年。</div></ul></ul><ul class="notion-list notion-list-disc notion-block-ff956ff2bd484bc68e7bb150205157b8"><li><b>安全性高</b></li><ul class="notion-list notion-list-disc notion-block-ff956ff2bd484bc68e7bb150205157b8"><div class="notion-text notion-block-a80d427232cc49fe9cec16d6296cf870">支持账户登陆二次验证和 Domain Defender，保护账户和域名安全。登陆、解锁域名等，都可以设置邮件或短信提醒。</div></ul></ul><ul class="notion-list notion-list-disc notion-block-f04d1561564a43049b7df5f3cda28cfd"><li><b>支付方便</b></li><ul class="notion-list notion-list-disc notion-block-f04d1561564a43049b7df5f3cda28cfd"><div class="notion-text notion-block-76bb23a518dd469fb8c93569c7a87dcc">支持支付宝、Paypal、信用卡等多种方式付款。</div></ul></ul><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-fd180b5939d245b6a60295cb7a8b3297" data-id="fd180b5939d245b6a60295cb7a8b3297"><span><div id="fd180b5939d245b6a60295cb7a8b3297" class="notion-header-anchor"></div><a class="notion-hash-link" href="#fd180b5939d245b6a60295cb7a8b3297" title="Vercel控制台添加域名"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">Vercel控制台添加域名</span></span></h2><ul class="notion-list notion-list-disc notion-block-db38ee8460d446e7a080f9e467a09be9"><li>在Vercel控制面板中找到<code class="notion-inline-code">Setting</code>→<code class="notion-inline-code">Domains</code>→<code class="notion-inline-code">Add</code>，在这里可以指定当前项目的绑定域名，一个项目可以绑定多个域名。</li></ul><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-7be4a76bf21f4ccda169d12fdbf288d2"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:336px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2Fbe0eead0-1ee4-446c-99c5-9cd410753da7%2FUntitled.png?table=block&amp;id=7be4a76b-f21f-4ccd-a169-d12fdbf288d2&amp;t=7be4a76b-f21f-4ccd-a169-d12fdbf288d2&amp;width=336&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><ul class="notion-list notion-list-disc notion-block-af58d3fcc582460d87dccc7be462202b"><li>输入域名,并Add之后，如果看到下图中的提示（<span class="notion-inline-underscore">Invalid Configuration</span>）👇, 说明域名已经添加，但需要根据提示添加CNAME或Nameserver的方式激活它，图中所示是要在域名后台添加一条CNAME类型的解析，参数名<code class="notion-inline-code">hexo</code>，值为<code class="notion-inline-code">cname.vercel-dns.com</code>。</li></ul><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-c1127ef1efdf4f988197655f1a2f0a34"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:384px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F87992b9b-8d90-4ee0-b202-e78aba10d4aa%2FUntitled.png?table=block&amp;id=c1127ef1-efdf-4f98-8197-655f1a2f0a34&amp;t=c1127ef1-efdf-4f98-8197-655f1a2f0a34&amp;width=384&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-2d04d88a0f60440eabf5f31b007666ab">这里推荐使用CNAME绑定。请按文档后续步骤配置对应的Cname解析。</div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-c7b213564fdb40ffb43b51ae31c08963" data-id="c7b213564fdb40ffb43b51ae31c08963"><span><div id="c7b213564fdb40ffb43b51ae31c08963" class="notion-header-anchor"></div><a class="notion-hash-link" href="#c7b213564fdb40ffb43b51ae31c08963" title="域名服务商解析CNAME"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">域名服务商解析CNAME</span></span></h2><div class="notion-text notion-block-dcb1127265584847ac4280549b40849f">以下分多个平台举例，配置方法大同小异，只是入口不太一样，我这里主要讲CloudFlare的配置方法</div><div class="notion-callout notion-gray_background_co notion-block-bb36bec5671649648e747fcd9eba9d28"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text">其它服务商的解析CNAME方法，可以参考<details class="notion-toggle notion-block-7c11f9c43d0f4858aa9511e04f0f4cd5"><summary>腾讯云托管域名</summary><div><div class="notion-text notion-block-7bf4f121162141f4a000b8783dce01f4"> <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://console.dnspod.cn/dns/list">https://console.dnspod.cn/dns/list</a> 点击域名进行配置，添加一条CNAME 转发</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-8cdb269d08054f28bfc4ba4933bd3d1f"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F941e26a1-5ef5-4551-b5cd-64e01e371568%2FUntitled.png?table=block&amp;id=8cdb269d-0805-4f28-bfc4-ba4933bd3d1f&amp;t=8cdb269d-0805-4f28-bfc4-ba4933bd3d1f&amp;width=672&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-5987f75d822844e6a04dc8e148e8834e"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2Ffb8b27c9-fece-4151-a785-bde23cae966d%2FUntitled.png?table=block&amp;id=5987f75d-8228-44e6-a04d-c8e148e8834e&amp;t=5987f75d-8228-44e6-a04d-c8e148e8834e&amp;width=2290&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></div></details><details class="notion-toggle notion-block-f6c5bc040cf5486e83a9c431e346be68"><summary>阿里云托管域名 </summary><div><div class="notion-text notion-block-29dfafe2fded4528a3577b2822e9c465">打开控制台 <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://dc.console.aliyun.com/#/domain-list/all">https://dc.console.aliyun.com/#/domain-list/all</a>  域名列表，点击域名，并添加一条cname转发</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-32899fb6afd64c1ab3e9310556d0a9f2"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F70e659d8-4ec1-4842-abb8-a404aa3193c0%2FUntitled.png?table=block&amp;id=32899fb6-afd6-4c1a-b3e9-310556d0a9f2&amp;t=32899fb6-afd6-4c1a-b3e9-310556d0a9f2&amp;width=620.0173950195312&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></div></details><details class="notion-toggle notion-block-e1e3c39be5004722a342c400e72d9a96"><summary>Freenom 购买的域名</summary><div><div class="notion-text notion-block-8789a8b4dc494627a1c5798fac046c4a">建议将域名的Nameservers 托管给 CloudFlare，然后在CloudFlare中设置</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-65782096ecd84ae69c367062b77fe701"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F9ad8a730-b6c8-44fc-932f-d881824df059%2FUntitled.png?table=block&amp;id=65782096-ecd8-4ae6-9c36-7062b77fe701&amp;t=65782096-ecd8-4ae6-9c36-7062b77fe701&amp;width=2348&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></div></details></div></div><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-109f93b9208b80be8888d7324216adec" data-id="109f93b9208b80be8888d7324216adec"><span><div id="109f93b9208b80be8888d7324216adec" class="notion-header-anchor"></div><a class="notion-hash-link" href="#109f93b9208b80be8888d7324216adec" title="域名转CloudFlare托管"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">域名转CloudFlare托管</span></span></h3><div class="notion-text notion-block-f23e94a95f694f38b67f15e21cf70368">域名服务商购买的域名，默认都会提供一个解析服务，但这个服务是可选的，我们可以通过修改Nameserver的方式，交给CloudFlare或其他DNS服务商进行解析和托管。</div><div class="notion-text notion-block-a2c5d62c2a044eb2b28d68d56c608604">CloudFlare具有Worker.js、全球免费CDN、SSL证书，网站DDoS防火墙等特性，我个人习惯将域名解析交给CloudFlare管理 。</div><ul class="notion-list notion-list-disc notion-block-109f93b9208b80dca361f79e3096e6d5"><li>如何将namesilo购买的域名放在CloudFlare中解析与托管？可参考《<b><a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://namesiloyouhui.com/cloudflare-dns-settings.html">NameSilo配置Cloudflare域名解析教程</a></b>》。</li></ul><ul class="notion-list notion-list-disc notion-block-109f93b9208b80bc9c3cc4f43811f1e0"><li>如何将阿里云购买的域名放在CloudFlare中解析与托管？ 具体配置方法可以参考《<a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://bbs.maozhishi.com/d/56-cloudflare">阿里云域名用CloudFlare解析域名</a>》。</li></ul><ul class="notion-list notion-list-disc notion-block-139f93b9208b80b8b99ee7168dcf7f03"><li>如何将Dynadot的域名放在CloudFlare中解析与托管？可参考《<a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://appscross.com/blog/dynadot-registered-domains-are-migrated-to-cloudflare.html">Dynadot注册的域名迁移至Cloudflare</a>》。</li></ul><div class="notion-text notion-block-ceb531c85155426ea92e79c67fa09572">只要在域名服务商后台，将NameServer修改成CloudFlare为你分配的地址即可。其它域名服务商的操作基本一致不再赘述。</div><div class="notion-callout notion-blue_background_co notion-block-109f93b9208b80c5b780dbfbba427939"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text"><div class="notion-text notion-block-69aea5598e8c42329d17f6f04afe734a">由于域名解析存在缓存，从不同服务商将DNS交给CloudFlare托管需要一个生效时间，也许十几分钟，也许几个小时。

在CloudFlare后台点击“立即检查名称服务器”可以查看是否生效，或者等待邮件通知。</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-109f93b9208b80df9d67df273c739953"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:672px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F548d546a-f558-4e32-a516-3fd4c3daa72b%2Fb9d36b3aa2ca475b12b96afcc8fe80b.png?table=block&amp;id=109f93b9-208b-80df-9d67-df273c739953&amp;t=109f93b9-208b-80df-9d67-df273c739953&amp;width=672&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></div></div><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-6bbd8a77b83344cf8cadf3af7ae12096" data-id="6bbd8a77b83344cf8cadf3af7ae12096"><span><div id="6bbd8a77b83344cf8cadf3af7ae12096" class="notion-header-anchor"></div><a class="notion-hash-link" href="#6bbd8a77b83344cf8cadf3af7ae12096" title="CloudFlare 解析 CNAME"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">CloudFlare 解析 CNAME</span></span></h3><ul class="notion-list notion-list-disc notion-block-dc48c6e457ef4717a4c1ffb7782f91f2"><li>打开CloudFlare控制台 <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://dash.cloudflare.com">https://dash.cloudflare.com</a>，并找到您的域名</li></ul><ul class="notion-list notion-list-disc notion-block-ab415a3f409e40ffaeedd9819c90238b"><li>若您的域名没有解析任何服务器<b>（即没有添加过任何一条A记录）</b>，需要添加一条域名A记录指向Vercel服务器地址<code class="notion-inline-code">76.76.21.21</code></li><ul class="notion-list notion-list-disc notion-block-ab415a3f409e40ffaeedd9819c90238b"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-006ce6a7c2684ebc956437cff7aaeaf3"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:576px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F1895f722-0256-4b45-ab4d-13cbe42dd9bd%2FUntitled.png?table=block&amp;id=006ce6a7-c268-4ebc-9564-37cff7aaeaf3&amp;t=006ce6a7-c268-4ebc-9564-37cff7aaeaf3&amp;width=576&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ul></ul><ul class="notion-list notion-list-disc notion-block-b69bf8ccd61c4b3cb2edc89b62554ec3"><li>按Vercel提示，添加一条CNAME记录值为Vercel的CNAME服务器：<code class="notion-inline-code">cname-china.vercel-dns.com</code> ;（vercel默认推荐<code class="notion-inline-code">cname.vercel-dns.com</code> ，但这个cname在大陆访问比较慢）</li><ul class="notion-list notion-list-disc notion-block-b69bf8ccd61c4b3cb2edc89b62554ec3"><div class="notion-text notion-block-f2b325f6e4824ffb9945cb674f6bf63e">下图是我的配置，这里举例使用的是二级域名 <a target="_blank" rel="noopener noreferrer" class="notion-link" href="http://hexo.tangly1024.com">hexo.tangly1024.com</a> </div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-ee8c6938178944089199ec971d438830"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:576px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2Fc62c2a2f-e28b-4b91-9c81-fd3361a0e27a%2FUntitled.png?table=block&amp;id=ee8c6938-1789-4408-9199-ec971d438830&amp;t=ee8c6938-1789-4408-9199-ec971d438830&amp;width=576&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-1c57d04d5c3a45c8b84cb9337091ce8c"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:576px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F95831505-6425-40f3-a2a8-fb2e2bbba49e%2FUntitled.png?table=block&amp;id=1c57d04d-5c3a-45c8-b84c-b9337091ce8c&amp;t=1c57d04d-5c3a-45c8-b84c-b9337091ce8c&amp;width=576&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-callout notion-blue_background_co notion-block-109f93b9208b802ea781c62059c6492f"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text"><div class="notion-text notion-block-9a00bb9d6d7349fa99c7beab9ac99a7e">如果添加后出现“没有证书覆盖此主机名。”的错误，先关闭CDN代理</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-109f93b9208b80679acdd9b552ff049a"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:318.9930725097656px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2Fe787d221-617e-4b3b-ba45-478b4618dff3%2Fimage.png?table=block&amp;id=109f93b9-208b-8067-9acd-d9b552ff049a&amp;t=109f93b9-208b-8067-9acd-d9b552ff049a&amp;width=318.9930725097656&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-109f93b9208b8023b343c0488e1b69ca">1.右边点编辑
2.点击修改代理状态（变成灰色仅DNS）
3. 然后保存</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-109f93b9208b8010b24dcc9f3211c218"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2Ff5534c85-ca12-402f-ae85-0203a42aa9ca%2Fimage.png?table=block&amp;id=109f93b9-208b-8010-b24d-cc9f3211c218&amp;t=109f93b9-208b-8010-b24d-cc9f3211c218&amp;width=619.982666015625&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></div></div></ul></ul><div class="notion-blank notion-block-feed4314372b41d89bcdc3850e3f81db"> </div><ul class="notion-list notion-list-disc notion-block-5ca8107c7ffc4253af904bbda61bdeb5"><li>添加成功后，还需要在ssl/tls配配置开启https完全加密 ， 否则会因为证书不匹配导致反复重定向而打不开网页。</li><ul class="notion-list notion-list-disc notion-block-5ca8107c7ffc4253af904bbda61bdeb5"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-f8ca9eacb3264dfe941bd315555eb66a"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:576px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F1793f92f-dc15-4dbb-9e3b-b4f64e05a34a%2FUntitled.png?table=block&amp;id=f8ca9eac-b326-4dfe-941b-d315555eb66a&amp;t=f8ca9eac-b326-4dfe-941b-d315555eb66a&amp;width=576&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-c92e6f3466834b648327940370d13452">如果没有开启SSL完全加密，网站会打开失败</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-e7977693b91146baa73a76b40c8a01e3"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:576px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2Fd0c3094c-51ff-4825-b65f-41260dc5ae4a%2FUntitled.png?table=block&amp;id=e7977693-b911-46ba-a73a-76b40c8a01e3&amp;t=e7977693-b911-46ba-a73a-76b40c8a01e3&amp;width=576&amp;cache=v2" alt="反复重定向，无法打开页面" loading="lazy" decoding="async"/><figcaption class="notion-asset-caption">反复重定向，无法打开页面</figcaption></div></figure></ul></ul><div class="notion-text notion-block-f338628e830c44ecb7658187b2115bd4">如果域名服务配置正常，Vercel的卡片会变成如图的样子：</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-9d4e7ce01b114b9d8db84da3ab748cf0"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:480px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2Ffedf17d5-f205-46c4-a06e-bba238b2233e%2FUntitled.png?table=block&amp;id=9d4e7ce0-1b11-4b9d-8db8-4da3ab748cf0&amp;t=9d4e7ce0-1b11-4b9d-8db8-4da3ab748cf0&amp;width=480&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><blockquote class="notion-quote notion-block-02ac54cd9a234cec97e36a98a06c74ec"><div>接下来就可以通过设置的域名（如 <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://hexo.tangly1024.com">https://hexo.tangly1024.com</a> ）访问我们的网站了</div></blockquote><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-c4a316ec61e346d3921e61d752187b7e" data-id="c4a316ec61e346d3921e61d752187b7e"><span><div id="c4a316ec61e346d3921e61d752187b7e" class="notion-header-anchor"></div><a class="notion-hash-link" href="#c4a316ec61e346d3921e61d752187b7e" title="关于根域名的配置"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">关于根域名的配置</span></span></h3><div class="notion-text notion-block-339e85512481482e98353ab19599fcb2">以上举例使用的是二级域名，如果你想像我一样使用 <a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://tangly1024.com">https://tangly1024.com</a> 这样的根域名，配置参考如下：</div><h4 class="notion-h notion-h3 notion-h-indent-2 notion-block-060198bb8ba746018083d793a1afd45c" data-id="060198bb8ba746018083d793a1afd45c"><span><div id="060198bb8ba746018083d793a1afd45c" class="notion-header-anchor"></div><a class="notion-hash-link" href="#060198bb8ba746018083d793a1afd45c" title="Vercel后台"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">Vercel后台</span></span></h4><div class="notion-text notion-block-f81a56c1849747d3b3b2b4e687f1bc33">直接添加根域名后，vercel会提示需要添加一条@记录指向vercel的服务器 76.76.21.21</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-283f6eaa09d14180a2c4e3df5ff816d5"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:528px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F64f3ec92-0b8b-4400-8583-dfaedc541c86%2FUntitled.png?table=block&amp;id=283f6eaa-09d1-4180-a2c4-e3df5ff816d5&amp;t=283f6eaa-09d1-4180-a2c4-e3df5ff816d5&amp;width=528&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><h4 class="notion-h notion-h3 notion-h-indent-2 notion-block-fea5ca2562fa4523a5c9d79f708959c7" data-id="fea5ca2562fa4523a5c9d79f708959c7"><span><div id="fea5ca2562fa4523a5c9d79f708959c7" class="notion-header-anchor"></div><a class="notion-hash-link" href="#fea5ca2562fa4523a5c9d79f708959c7" title="域名管理后台"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">域名管理后台</span></span></h4><div class="notion-text notion-block-a30eba115efa4bd1bb3874812c5947e6">直接将根域名 解析到 vercel的服务器地址即可 ： 76.76.21.21</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-e5886869ce9d4443a261d21f4e528d0e"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F434d3ad6-8848-4fc9-b95a-a77420978c64%2FUntitled.png?table=block&amp;id=e5886869-ce9d-4443-a261-d21f4e528d0e&amp;t=e5886869-ce9d-4443-a261-d21f4e528d0e&amp;width=2062&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-b95cf4d2014e41f38c99ff4db327b912">添加根域名的时候，vercel会提示选择以下三种方案，针对个人博客而言，为了让域名简洁，我推荐选择第一种方案，  将www开头的二级域名也重定向到根域名tangly1024.com。</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-4c587b77a62e4736ab4d6a26a3144521"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:528px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2Ff892e7b5-fed9-44ad-93ba-6fa0493ab574%2FUntitled.png?table=block&amp;id=4c587b77-a62e-4736-ab4d-6a26a3144521&amp;t=4c587b77-a62e-4736-ab4d-6a26a3144521&amp;width=528&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-b44d8c7b48f44027a4d54176e7f63086">完成效果</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-b04cd5edf0b84fdda7a17189d546a00b"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:100%;max-width:100%;flex-direction:column;height:100%"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fs3-us-west-2.amazonaws.com%2Fsecure.notion-static.com%2F223967aa-26c2-422f-b019-fc95de3767d5%2FUntitled.png?table=block&amp;id=b04cd5ed-f0b8-4fdd-a7a1-7189d546a00b&amp;t=b04cd5ed-f0b8-4fdd-a7a1-7189d546a00b&amp;width=707.9861450195312&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-blank notion-block-e3d806eb5e9a4dfab7337dc51b9b3f6a"> </div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-155f5cdd70c140029da0302f42c4aba5" data-id="155f5cdd70c140029da0302f42c4aba5"><span><div id="155f5cdd70c140029da0302f42c4aba5" class="notion-header-anchor"></div><a class="notion-hash-link" href="#155f5cdd70c140029da0302f42c4aba5" title="域名与NotionNext配置"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">域名与NotionNext配置</span></span></h2><div class="notion-text notion-block-150f93b9208b80ef9fc4df0e2ac3a2b3">您的新域名绑定后，请配置到NotionNext项目中，配置方法推荐用环境变量:</div><div class="notion-text notion-block-150f93b9208b8049bd55f6c14b59eee1">在Vercel后台添加如下变量：</div><table class="notion-simple-table notion-block-150f93b9208b80828298d35ea29146d7"><tbody><tr class="notion-simple-table-row notion-block-64422ea4dc194125a926eeb22aa02e0a"><td class="" style="width:120px"><div class="notion-simple-table-cell">变量名</div></td><td class="" style="width:395px"><div class="notion-simple-table-cell">变量值</div></td></tr><tr class="notion-simple-table-row notion-block-ed143f1d00504f12bfb2fe3be592d73b"><td class="" style="width:120px"><div class="notion-simple-table-cell">NEXT_PUBLIC_LINK</div></td><td class="" style="width:395px"><div class="notion-simple-table-cell">http://xx.com</div></td></tr></tbody></table></main></div>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[NotionNext项目运行原理]]></title>
            <link>https://docs.tangly1024.com/article/vercel-notionnext-notion</link>
            <guid>https://docs.tangly1024.com/article/vercel-notionnext-notion</guid>
            <pubDate>Mon, 18 Nov 2024 00:00:00 GMT</pubDate>
            <description><![CDATA[简单介绍一下vercel、notion、notionnext三者关系]]></description>
            <content:encoded><![CDATA[<div id="notion-article" class="mx-auto overflow-hidden "><main class="notion light-mode notion-page notion-block-142f93b9208b80939821c597a918ee10"><div class="notion-viewport"></div><div class="notion-collection-page-properties"></div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-142f93b9208b80e8af61d909eb2f47e8" data-id="142f93b9208b80e8af61d909eb2f47e8"><span><div id="142f93b9208b80e8af61d909eb2f47e8" class="notion-header-anchor"></div><a class="notion-hash-link" href="#142f93b9208b80e8af61d909eb2f47e8" title="关于本篇"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">关于本篇</span></span></h2><div class="notion-text notion-block-142f93b9208b80359213f655b43d930f">在这里我简单介绍一下NotionNext项目的运行原理，以及Notion、Vercel、NotionNext三者的关系。</div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-142f93b9208b805c9e60e2141ae8f54f" data-id="142f93b9208b805c9e60e2141ae8f54f"><span><div id="142f93b9208b805c9e60e2141ae8f54f" class="notion-header-anchor"></div><a class="notion-hash-link" href="#142f93b9208b805c9e60e2141ae8f54f" title="关于解决方案"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">关于解决方案</span></span></h2><div class="notion-text notion-block-142f93b9208b80d581c5dd6719ee768f">传统的网站建设，可能会用到的方案：</div><ul class="notion-list notion-list-disc notion-block-142f93b9208b80f5ab39dbecc921fab3"><li>首先：租一台<b>云服务器</b>；</li></ul><ul class="notion-list notion-list-disc notion-block-142f93b9208b80648df6da99f4a3771f"><li>其次：将网站的<b>代码，</b>例如WordPress或自研的网页上传到到服务器中；</li></ul><ul class="notion-list notion-list-disc notion-block-142f93b9208b805db458c0e494e97433"><li>然后：在服务器中自行部署一个<b>数据库</b>，或者向云服务商购买一个数据库。</li></ul><ul class="notion-list notion-list-disc notion-block-142f93b9208b80e1a9adcfea79105786"><li>接着：以服务器为核心，<b>运行代码</b>，并从数据库中读取网页数据。</li></ul><ul class="notion-list notion-list-disc notion-block-142f93b9208b8069b6d4c0b5d878088b"><li>最后：购买一个<b>域名</b>，将域名绑定在这台服务器的ip地址上。</li></ul><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-142f93b9208b80ada57ae2dad5237bd3" data-id="142f93b9208b80ada57ae2dad5237bd3"><span><div id="142f93b9208b80ada57ae2dad5237bd3" class="notion-header-anchor"></div><a class="notion-hash-link" href="#142f93b9208b80ada57ae2dad5237bd3" title="对比"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">对比</span></span></h3><div class="notion-text notion-block-142f93b9208b8024953af5df6022f5fa">NotionNext的站点本质也是一样的，只是做了元件的替换，即：把服务器、代码、数据库换了别的替代方案。</div><ol start="1" class="notion-list notion-list-numbered notion-block-142f93b9208b80338105e23e73541da5" style="list-style-type:decimal"><li>首先：注册了一个<b>Vercel云平台</b>：主要提供CPU算力、内存空间、操作系统以及运行环境。</li></ol><ol start="2" class="notion-list notion-list-numbered notion-block-142f93b9208b805bade8c2351da69a1e" style="list-style-type:decimal"><li>其次：注册了一个<b>Github平台</b>：主要提供协同开发、代码存储与版本管理。<b>NotionNext</b>的代码就可以托管在平台进行维护。</li></ol><ol start="3" class="notion-list notion-list-numbered notion-block-142f93b9208b804d818fd1efdef19d49" style="list-style-type:decimal"><li>然后：注册了一个<b>Notion笔记</b>：将文字、图片等内容存储在笔记中，</li></ol><ol start="4" class="notion-list notion-list-numbered notion-block-142f93b9208b8073adc2d1a1a3bdad0e" style="list-style-type:decimal"><li>接着：以<b>Vercel</b>为核心，从Github中拉取最新版本的代码、编译运行、并从Notion中读取网页数据，按照NotionNext编码的规则展示网页。</li></ol><ol start="5" class="notion-list notion-list-numbered notion-block-142f93b9208b80b98d25e23e2fe51c20" style="list-style-type:decimal"><li>最后：将购买的<b>域名，</b>解析到Vercel云平台提供给我们的服务器地址，Vercel负责将域名进一步解析到项目上。</li></ol><div class="notion-blank notion-block-142f93b9208b80f9a380f4f33150263b"> </div><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-142f93b9208b8099b74cd7d463bd09ab" data-id="142f93b9208b8099b74cd7d463bd09ab"><span><div id="142f93b9208b8099b74cd7d463bd09ab" class="notion-header-anchor"></div><a class="notion-hash-link" href="#142f93b9208b8099b74cd7d463bd09ab" title="小结"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">小结</span></span></h3><div class="notion-text notion-block-142f93b9208b8060bbe6e0160d7951ea">这里我们可以看到，<b>Vercel替代了服务器的概念</b>，<b>Notion充当一个数据库</b>、<b>NotionNext则是核心的代码</b>。</div><div class="notion-text notion-block-142f93b9208b8092adbdf2b746b1f00c">按我的个人习惯来说，之所以选用这种替代方案，取决于三个痛点：</div><ol start="1" class="notion-list notion-list-numbered notion-block-142f93b9208b80e4a63cd684661af9b8" style="list-style-type:decimal"><li>写作：用Notion写笔记的方式来写文章更加舒适而且长远可持续。用公众号编辑、WordPress后台、用第三方博客平台发布页来写文章，要养成习惯太难。用自己的笔记本写东西才能让我不费力，或者用着舒服，这样才有可能做的长久，做的长久，才有可能做得好。</li></ol><ol start="2" class="notion-list notion-list-numbered notion-block-142f93b9208b80ae99d7c16dbdf87eb8" style="list-style-type:decimal"><li>维护：服务器的安全、升级，数据库的备份、维护，需要耗费一些精力；更可怕的是这种折腾服务器的成就感会让人上瘾，你会不断地从搭建服务器、搭建网站的过程中获得”甜头“，从而沉迷于折腾软件技术。</li></ol><ol start="3" class="notion-list notion-list-numbered notion-block-142f93b9208b805c97f5f074e72a4f55" style="list-style-type:decimal"><li>费用：服务器、域名、我只想发布博客文字，有必要那么贵租一年的服务器吗？</li></ol><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-142f93b9208b8067978fefbaa7e97bab" data-id="142f93b9208b8067978fefbaa7e97bab"><span><div id="142f93b9208b8067978fefbaa7e97bab" class="notion-header-anchor"></div><a class="notion-hash-link" href="#142f93b9208b8067978fefbaa7e97bab" title="工作流程"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">工作流程</span></span></h2><div class="notion-text notion-block-142f93b9208b808caf83fbdefb5bc35d">接下来，看看这个项目的首次安装、运行，与更新、升级配置过程中，发生了哪些事？</div><div class="notion-blank notion-block-142f93b9208b80498ed4c431b60a4083"> </div><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-142f93b9208b8067afebc63f385f943e" data-id="142f93b9208b8067afebc63f385f943e"><span><div id="142f93b9208b8067afebc63f385f943e" class="notion-header-anchor"></div><a class="notion-hash-link" href="#142f93b9208b8067afebc63f385f943e" title="首次安装"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">首次安装</span></span></h3><div class="notion-text notion-block-142f93b9208b8015ab9ff2ce99e09293">《<a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://docs.tangly1024.com/article/vercel-deploy-notion-next">Vercel部署NotionNext</a>》这篇教程详细介绍了部署的方法；部署的过程发生了什么呢？</div><div class="notion-blank notion-block-142f93b9208b8024addeea51be04b526"> </div><ol start="1" class="notion-list notion-list-numbered notion-block-142f93b9208b80ef8e3acef18a5043bd" style="list-style-type:decimal"><li>用户首先要复制我的Notion数据库作为模板</li><ol class="notion-list notion-list-numbered notion-block-142f93b9208b80ef8e3acef18a5043bd" style="list-style-type:lower-alpha"><div class="notion-text notion-block-142f93b9208b80bdb81ed2fcd18e1cd4">Notion充当数据库的角色，所有支持的表头和字段，都已经在NotionNext代码中固定了，如果表头字段不一致，将导致数据无法被正常读取。</div><div class="notion-text notion-block-142f93b9208b8027a7d3ce37e5c4f516">用户复制模板的这一过程就相当于在Notion创建了一个属于自己的、NotionNext能识别的数据库。</div></ol></ol><ol start="2" class="notion-list notion-list-numbered notion-block-142f93b9208b808ba1e4fce2191d1842" style="list-style-type:decimal"><li>用户注册Github平台，并且复制一份NotionNext代码</li><ol class="notion-list notion-list-numbered notion-block-142f93b9208b808ba1e4fce2191d1842" style="list-style-type:lower-alpha"><div class="notion-text notion-block-142f93b9208b80ba899ef91675989f55">代码是核心，但是如何做到所有用户都能公开拉取到代码，并且还能随时更新代码，甚至一起参与到代码的开发呢？</div><div class="notion-text notion-block-142f93b9208b806c8b1bdbe5ff6d01df">Github就是一个程序员们最爱的代码协同管理平台，他就类似于腾讯云文档这样的软件，大家都可以参与一个文档的在线编辑，还可以有版本管理的功能，可以记录并回退到任意一个版本中。</div></ol></ol><ol start="3" class="notion-list notion-list-numbered notion-block-142f93b9208b80b4a8c3fd684cb867c3" style="list-style-type:decimal"><li>注册一个Vercel平台</li><ol class="notion-list notion-list-numbered notion-block-142f93b9208b80b4a8c3fd684cb867c3" style="list-style-type:lower-alpha"><div class="notion-text notion-block-142f93b9208b808693b5e60cb8ad939b">前面已经解决了代码和数据库的问题，最后就是解决服务器的问题。</div><div class="notion-text notion-block-142f93b9208b804291a7d4bf861884c9">登陆Vercel后，你可以选择将代码上传到Vercel平台中进行部署。但Vercel支持一个更强大的功能，就是直接与你的Github仓库建立实时链接。</div><div class="notion-text notion-block-142f93b9208b80ce97f4f89509d214ed">Vercel将24小时监听你的Github仓库代码，一旦发生更新或改动，它会自行到您的仓库中拉取最新代码，进行打包编译。</div><div class="notion-text notion-block-142f93b9208b80448c09f2a5ed66b30a">从而实现：你无需关注服务器与部署，只要管好自己在Github中的代码即可。打个比方，这时候你是公司的开发人员，只负责代码规则；服务器的运维任务则交给了一个24小时在线的团队管理。</div><div class="notion-text notion-block-28df93b9208b80bebaf1e8f52eed0139">在新版本的NotionNext，绝大部分的代码配置都支持直接在Notion中配置，这样可以实现，你无需关心代码，只要专注在Notion中配置站点，维护文章内容即可。</div></ol></ol><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-142f93b9208b8047bafbde967353260d" data-id="142f93b9208b8047bafbde967353260d"><span><div id="142f93b9208b8047bafbde967353260d" class="notion-header-anchor"></div><a class="notion-hash-link" href="#142f93b9208b8047bafbde967353260d" title="NotionNext的运作过程"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">NotionNext的运作过程</span></span></h2><div class="notion-text notion-block-142f93b9208b80ce822fec6165ba92bb">Vercel 云计算运行 NotionNext代码，不断从你的Notion数据库拉取文章，排版成网站。Notion数据发生变化后，网站数据也会跟着改变。若用纯技术的语言来描述可能比较晦涩难懂，我接下来用打比喻的方式来介绍这个项目的工作原理。</div><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-142f93b9208b80cabc40e63e1c2a3737" data-id="142f93b9208b80cabc40e63e1c2a3737"><span><div id="142f93b9208b80cabc40e63e1c2a3737" class="notion-header-anchor"></div><a class="notion-hash-link" href="#142f93b9208b80cabc40e63e1c2a3737" title="NotionNext小店"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">NotionNext小店</span></span></h3><div class="notion-text notion-block-142f93b9208b8079860fcedf58044091">NotionNext搭建的站点像一个小餐馆，店铺有招牌门头、有来自网络的客流。客人可以看到店铺的门面、进店查看菜单、并选择要点的菜。</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-142f93b9208b8079af24c52bfecd525f"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:336px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F53369917-7a48-44cd-bbe0-2e42c931a131%2Fdownload.jpg?table=block&amp;id=142f93b9-208b-8079-af24-c52bfecd525f&amp;t=142f93b9-208b-8079-af24-c52bfecd525f&amp;width=336&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-142f93b9208b80fbadb5de194e7f7915">店铺与传统餐饮店不同，店里没有烹饪菜品用的厨房，没有专业的厨师。所有菜都是从Notion那边进货的<b>预制菜</b>；Notion是NotionNext店铺唯一指定的供应商、又或者可以称之为<b>中央厨房</b>。</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-142f93b9208b805c85a2dcaf33f1b5a7"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:336px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F4735954b-2f8f-440d-811e-07d3f7476389%2Fimage.png?table=block&amp;id=142f93b9-208b-805c-85a2-dcaf33f1b5a7&amp;t=142f93b9-208b-805c-85a2-dcaf33f1b5a7&amp;width=336&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-142f93b9208b80bb886efc1e8edcdf5a">店里有很多“店小二”，店小二是由Vercel云平台提供的<b>CPU、硬盘、内存</b>等构成的员工，他们听从门店的指挥、按照代码设计好的店规流程办事。</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-142f93b9208b80248a74e9d0d6848e0d"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:336px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F4de02e93-2fce-47c7-bcb8-2f1ff1652c21%2Fimage.png?table=block&amp;id=142f93b9-208b-8024-8a74-e9d0d6848e0d&amp;t=142f93b9-208b-8024-8a74-e9d0d6848e0d&amp;width=336&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-155f93b9208b809593a1d9df228d908d">店小二主要做以下几件件事：</div><ol start="1" class="notion-list notion-list-numbered notion-block-164f93b9208b8093923cce3176d17060" style="list-style-type:decimal"><li>去Notion进货，在代码中指定了小二要去哪个Notion页面进货（配置NOTION_PAGE_ID）</li></ol><ol start="2" class="notion-list notion-list-numbered notion-block-155f93b9208b8042a1d5c1c744df352d" style="list-style-type:decimal"><li>接客：根据客人点菜时他们将预制菜放进微波炉加热。</li><ol class="notion-list notion-list-numbered notion-block-155f93b9208b8042a1d5c1c744df352d" style="list-style-type:lower-alpha"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-155f93b9208b8022b870d6e2a0b26011"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:299.9653015136719px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F8141fe09-2e54-4d8f-a6ba-1269e615c9b7%2Fimages.jpg?table=block&amp;id=155f93b9-208b-8022-b870-d6e2a0b26011&amp;t=155f93b9-208b-8022-b870-d6e2a0b26011&amp;width=299.9653015136719&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ol></ol><ol start="3" class="notion-list notion-list-numbered notion-block-155f93b9208b807b827ede8f2b4b003e" style="list-style-type:decimal"><li><b>将菜品呈在盘子里</b>给客人上菜。NotionNext提供多种盘子的主题、例如Hexo、Gitbook等、店长可以配置选择主题来决定用什么呈现方式交付客户。</li><ol class="notion-list notion-list-numbered notion-block-155f93b9208b807b827ede8f2b4b003e" style="list-style-type:lower-alpha"><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-155f93b9208b80a68474e2e53386f6a7"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:288px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F65bd23cb-6edd-4017-b69e-2eb4a4593b48%2Fimage.png?table=block&amp;id=155f93b9-208b-80a6-8474-e2e53386f6a7&amp;t=155f93b9-208b-80a6-8474-e2e53386f6a7&amp;width=288&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure></ol></ol><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-142f93b9208b80cfa0e1dc5640c233bf" data-id="142f93b9208b80cfa0e1dc5640c233bf"><span><div id="142f93b9208b80cfa0e1dc5640c233bf" class="notion-header-anchor"></div><a class="notion-hash-link" href="#142f93b9208b80cfa0e1dc5640c233bf" title="节能减排的NotionNext"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">节能减排的NotionNext</span></span></h2><div class="notion-text notion-block-142f93b9208b801789fccc2fd7d9d36c">NotionNext是一个提倡节能减排的店。</div><div class="notion-text notion-block-155f93b9208b80a3867cefd7f2bd44f8">店铺首次开张时，会从Notion把每种菜都进一批货，把这批<b>菜品</b>就保存在<b>仓库里</b>(仓库指的是Vercel的硬盘和内存)。</div><div class="notion-text notion-block-142f93b9208b8067888cf125e20edf6e">当店里没客人时，店里的员工一动不动；店员不会主动去热菜、不会去进货、也不用招呼客人，甚至店里为了省电都不开灯。</div><div class="notion-text notion-block-155f93b9208b80bab84dd89e6433fb09">Vercel店员有一个特点，他们都是外包的临时工，或称共享员工。当店里没事情做时，他们会按照Vercel人力资源公司的调度，去到别的店里打工。</div><div class="notion-text notion-block-155f93b9208b8045b20bf974d06431f2">当客户通过网站地址访问店铺，需要有人干活时，Vercel会自动在第一时间调人过来帮忙。</div><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-142f93b9208b80bba77cf58def5419fe" data-id="142f93b9208b80bba77cf58def5419fe"><span><div id="142f93b9208b80bba77cf58def5419fe" class="notion-header-anchor"></div><a class="notion-hash-link" href="#142f93b9208b80bba77cf58def5419fe" title="上菜流程"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">上菜流程</span></span></h3><blockquote class="notion-quote notion-block-158f93b9208b80fc9d8fdcd076e38e26"><div>若店里来了客人，会发生什么？</div></blockquote><div class="notion-text notion-block-158f93b9208b8007a756c4d8c21bd6d9">客人走进店铺的大门，店里会派出一名小二，扮演跑堂的角色，他们会关注客人的一举一动，例如客人眼睛看向哪道菜，或者手指指向哪道菜，小二都会通过对讲机通知后厨检查库存并提前热菜。同时这个店小二还会按照店长指定的规则，主动向客人展示推荐当季的热门菜。</div><blockquote class="notion-quote notion-block-142f93b9208b800d9d3bea01dd8b7f1b"><div>客人点菜后，上菜流程是怎么样的？</div></blockquote><div class="notion-text notion-block-142f93b9208b8005b0a7e8fa3a412275">客人径直走进店铺，直接点了首页的某道招牌菜。这时候，跑堂会通知店小二会去仓库里找这<b>道菜</b>，看看是否有没有上次取来的库存：</div><div class="notion-text notion-block-142f93b9208b80bc99ffd2d612a99034">若有，就先把这道库存菜拿来，检查一下有没有变质，如果在保鲜期许可内，则用微波炉热一下，然后<b>呈在盘子里</b>拿给用户；同时会通知后台派另一个“店小二”，去Notion取一下最新的菜，取回来放在仓库里备用。</div><div class="notion-text notion-block-142f93b9208b80a3b6b5de5526d1d2a6">若客户点的菜店里没有库存，店铺就会让用户等一会儿，让小二优先加急去取菜，取到了马上给用户热菜、 上菜。</div><blockquote class="notion-quote notion-block-142f93b9208b80638e85ed6b78eeb773"><div>那这样用户访问的体验会不会不好？有的上菜慢，有的菜都凉了、或者不新鲜。</div></blockquote><div class="notion-text notion-block-142f93b9208b808fb44cd485c9ff71b2">关于上菜慢的问题，客户来点菜时，小二会一次性热好几份菜备着，并且设定菜变质和凉掉的时间，例如30秒钟，在这30秒内有新客点这道菜的话，小二不用热菜也可以直接上。超时的菜就要“回炉重造”。</div><div class="notion-text notion-block-155f93b9208b800da2b4fd0da32451dc">关于菜品不是最新的，小二虽然不会主动去Notion取新菜，但是上个客户来点菜时，店小二会同时去检查有没有新货取来备用。这样后续新客来店里就能刚好吃上最新的菜。</div><div class="notion-text notion-block-28df93b9208b803197d4cc8959f109ce">这样设计流程的特点是：客户点的频繁的菜，更新的也勤快；而客户不常点的菜，即使是再新鲜的热菜又有何用？店铺里往往是20%的菜品带来80%的收益，剩下的80%的菜仅仅作为陪衬。</div><div class="notion-text notion-block-155f93b9208b80eab69de7c8104ceb83">另一方面，若不是资深同行，80%的客人通常品尝不出菜是否新鲜。你肯定觉得老板是奸商、但这就是事实，商人除了考虑口碑，还要考虑成本和效益，在用户能够接受的情况下，尽量降低成本。</div><div class="notion-text notion-block-28df93b9208b80a28ae8f299bcca1ce3">这里可以发现，Notion小店的理念不是在追求100分的完美，而是将有限的、80%的精力资源，投入到大概率会发生的，有实用价值的事情中，将整体店铺的体验分数做到80分。</div><blockquote class="notion-quote notion-block-142f93b9208b800e98d1e8e3db409c7a"><div>若你研发了一道新菜在Notion里，想让NotionNext店铺的客户第一时间能品尝到要怎么做？</div></blockquote><div class="notion-text notion-block-142f93b9208b80c9aae9ec4a0bde70ae">很容易，自己点一单。你自己作为客户，到店里，指名要点那道菜即可，小儿会帮你去备好菜。类似于给自己刷单。另外，还有一种笨办法，就是店铺打烊并重新开张，让小二去重新进货（这就是在vercel后台redeploy的过程）。</div><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-142f93b9208b80d48fb8c0e100bcaf85" data-id="142f93b9208b80d48fb8c0e100bcaf85"><span><div id="142f93b9208b80d48fb8c0e100bcaf85" class="notion-header-anchor"></div><a class="notion-hash-link" href="#142f93b9208b80d48fb8c0e100bcaf85" title="更新站点"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">更新站点</span></span></h2><div class="notion-text notion-block-142f93b9208b80debe02cc0b5ba29f1c">前面讲到NotionNext这家店的上菜流程，接下来讲讲和Vercel、Notion的合作关系，也就是店铺的升级迭代。店铺开久了，难免想升级装修门面，或者培训员工提升一下工作效率。这时候发生了什么呢？</div><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-142f93b9208b80a7bec2dbdd23aee458" data-id="142f93b9208b80a7bec2dbdd23aee458"><span><div id="142f93b9208b80a7bec2dbdd23aee458" class="notion-header-anchor"></div><a class="notion-hash-link" href="#142f93b9208b80a7bec2dbdd23aee458" title="NotionNext加盟店"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">NotionNext加盟店</span></span></h3><div class="notion-text notion-block-142f93b9208b8094a72feb7a84332f54">比起直营分店，我更喜欢连锁加盟，自己开店不如召集大家一起开店来的有趣。</div><div class="notion-text notion-block-28df93b9208b8062802bc82cf6c9cf98">而NotionNext其实就像是一个连锁加盟品牌。</div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-142f93b9208b8026a3cdd4f616788be2"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:336px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F00ed3647-cad3-4ccf-a6e6-dbb1fd84ae05%2Fimage.png?table=block&amp;id=142f93b9-208b-8026-a3cd-d4f616788be2&amp;t=142f93b9-208b-8026-a3cd-d4f616788be2&amp;width=336&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-text notion-block-142f93b9208b802c8ad7da5d2ac256e8">品牌维护、运营中心都在tangly的中央仓库中，tangly日常负责规划设计NotionNext的工作流程、打造NotionNext旗舰店铺的装修样板。并把这些跑通的流程记录在<b>运营手册</b>，也就是<b>代码</b>中。</div><div class="notion-callout notion-gray_background_co notion-block-142f93b9208b80b3b585d42c50f930ff"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="⚠️">⚠️</span></div><div class="notion-callout-text"><div class="notion-text notion-block-8753d40b09bc4c21b417c1b924cd7299">NotionNext店铺的<b>运营手册</b>指的就是项目的代码。</div></div></div><figure class="notion-asset-wrapper notion-asset-wrapper-image notion-block-155f93b9208b8021aa98d860cc08dd86"><div style="position:relative;display:flex;justify-content:center;align-self:center;width:336px;max-width:100%;flex-direction:column"><img style="object-fit:cover" src="https://www.notion.so/image/https%3A%2F%2Fprod-files-secure.s3.us-west-2.amazonaws.com%2F6c096b44-beb9-48ee-8f92-1efdde47f3a3%2F54ab7fbe-01c3-459d-b7cf-2865d1f09ed5%2Fimage.png?table=block&amp;id=155f93b9-208b-8021-aa98-d860cc08dd86&amp;t=155f93b9-208b-8021-aa98-d860cc08dd86&amp;width=336&amp;cache=v2" alt="notion image" loading="lazy" decoding="async"/></div></figure><div class="notion-blank notion-block-142f93b9208b803a96a5e9aee277cc85"> </div><div class="notion-text notion-block-142f93b9208b80e286ccc84b244d6365">任何人都可以通过复制手册的方式免费加盟。</div><div class="notion-text notion-block-142f93b9208b8000a274d0084287fde3">当有新版的NotionNext店铺<b>运营手册</b>出来后，其它加盟商可以获取最新的“装修方案”、“员工培训手册”、从而带回去提升自己的门店运营效率。</div><blockquote class="notion-quote notion-block-142f93b9208b800e9a97fec1ec760bde"><div>这时候作为加盟商要怎么升级自己的门店呢？</div></blockquote><div class="notion-text notion-block-142f93b9208b80f6b285f1afc3a9b4df">首先，要获取最新的<b>运营手册</b>，手册在tangly的github仓库中，通过<b>同步代码</b>的方式就可以获取最新的手册。</div><blockquote class="notion-quote notion-block-155f93b9208b8084ab41fd90108602c6"><div>我们的所有加盟商都享有终生免费更新手册的权益</div></blockquote><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-155f93b9208b80838665f2ef518d67ae" data-id="155f93b9208b80838665f2ef518d67ae"><span><div id="155f93b9208b80838665f2ef518d67ae" class="notion-header-anchor"></div><a class="notion-hash-link" href="#155f93b9208b80838665f2ef518d67ae" title="更新手册的问题"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">更新手册的问题</span></span></h3><div class="notion-text notion-block-142f93b9208b80c3938cf86ca9a09469">需要注意的是，这时候有的加盟商会<b>更新手册失败</b>，这是因为他们在运营自己的店铺时，对手册做出了一些个性化的修改，从而更加符合自身的运营策略和使用习惯，从而导致合并手册的过程中出现分歧。</div><div class="notion-text notion-block-142f93b9208b80c6a5adf0b44ab86060">这种现象是常见的，毕竟不同地区、口味不同，有的菜谱偏咸，有的菜谱偏甜，不可能一个方案适用所有用户。</div><div class="notion-text notion-block-142f93b9208b80458837d22ac076d245">通常这里会有几种处理方法；</div><div class="notion-callout notion-gray_background_co notion-block-142f93b9208b80fa83b1cfb9fb438552"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="⚠️">⚠️</span></div><div class="notion-callout-text"><div class="notion-text notion-block-cc4a224e7eb845dfb511ccc11d28814e">这里的手册比喻的是你的Github代码。</div></div></div><ol start="1" class="notion-list notion-list-numbered notion-block-142f93b9208b80b882feefe81e38e4a7" style="list-style-type:decimal"><li>加盟商备份自己的手册，先完全照搬Tangly的手册运营店铺覆盖自己当前的手册、确保店铺能正常运营。然后再按照自己备份的个性化手册，一点点微调新版的手册内容。</li></ol><ol start="2" class="notion-list notion-list-numbered notion-block-142f93b9208b80439717fef153b37aa4" style="list-style-type:decimal"><li>资深专业的职业经理人，可以做到一边合并手册，一边核对条款的冲突，直接合并成最终版手册。</li></ol><ol start="3" class="notion-list notion-list-numbered notion-block-142f93b9208b80079877d40099c4899e" style="list-style-type:decimal"><li>请总部过来指导，tangly会根据加盟商自定义手册的方式，为加盟商量身定做出最适合加盟商的版本。</li></ol><div class="notion-callout notion-gray_background_co notion-block-142f93b9208b804c8415ee63822587b0"><div class="notion-page-icon-inline notion-page-icon-span"><span class="notion-page-icon" role="img" aria-label="💡">💡</span></div><div class="notion-callout-text"><div class="notion-text notion-block-142f93b9208b80b28a15c1f814f345bc">加盟商只需要做好手册的更新，Vercel会自动派店小二来按照手册装修店铺、培训小二。</div></div></div><h3 class="notion-h notion-h2 notion-h-indent-1 notion-block-142f93b9208b8032b6f3ca5e0aa441ff" data-id="142f93b9208b8032b6f3ca5e0aa441ff"><span><div id="142f93b9208b8032b6f3ca5e0aa441ff" class="notion-header-anchor"></div><a class="notion-hash-link" href="#142f93b9208b8032b6f3ca5e0aa441ff" title="一些优化的体验"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">一些优化的体验</span></span></h3><blockquote class="notion-quote notion-block-142f93b9208b8095bff9d1f2484624a4"><div>有的加盟商发现，更新手册时遇到很多冲突很麻烦，但是又想定制化，该怎么办？</div></blockquote><div class="notion-text notion-block-142f93b9208b80bdb8cee82a290accd7">NotionNext 支持你直接在自己的Notion数据库中定制手册，也就是<a target="_blank" rel="noopener noreferrer" class="notion-link" href="https://docs.tangly1024.com/article/how-to-config-notion-next">NOTION_CONFIG</a>。</div><div class="notion-text notion-block-142f93b9208b80c8b48bddac970001f8">店小二除了听从NotionNext店铺的规则外，也会从Notion中取来NOTION_CONFIG作为本地化的规则，且它的优先级高于总店的规则。</div><div class="notion-text notion-block-142f93b9208b809a8558ca74b128a0c3">NOTION_CONFIG中可以支持用户配置自己的装修样式和运行规则，如果不希望再升级店铺时本店手册与总店手册冲突，可以尝试一下。</div><div class="notion-text notion-block-142f93b9208b80aea3faf05d20c3f66a">另外，有的店铺想要自行设计店里的餐盘和门店的样式，我推荐加盟商在手册中，另外创建一个附件，在里面编辑自己的内容，而不要改动现有的手册内容。</div><blockquote class="notion-quote notion-block-155f93b9208b80bfa955db94988cb49c"><div>这里的附件指的就是，加盟商创建自己的主题文件夹，而不是修改现有主题的内容。例如复制一个hexo主题，然后命名为new主题，然后都在这个new主题里修改即可。又或者重新拉取一个代码分支，所有改动在自己的分支里，从而不影响主分支的自动升级。</div></blockquote><h2 class="notion-h notion-h1 notion-h-indent-0 notion-block-142f93b9208b809db830ccb68a54f028" data-id="142f93b9208b809db830ccb68a54f028"><span><div id="142f93b9208b809db830ccb68a54f028" class="notion-header-anchor"></div><a class="notion-hash-link" href="#142f93b9208b809db830ccb68a54f028" title="最后"><svg viewBox="0 0 16 16" width="16" height="16"><path fill-rule="evenodd" d="M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z"></path></svg></a><span class="notion-h-title">最后</span></span></h2><div class="notion-text notion-block-142f93b9208b808bab45ee68d234c0f8">感谢您的阅读，文章暂时更新到这里，后面有想到新的内容再更新。</div></main></div>]]></content:encoded>
        </item>
    </channel>
</rss>