,
- }>
}
module GetStaticPaths = {
diff --git a/src/common/CompilerManagerHook.res b/src/common/CompilerManagerHook.res
index 99a1a97c7..6243fe240 100644
--- a/src/common/CompilerManagerHook.res
+++ b/src/common/CompilerManagerHook.res
@@ -35,10 +35,7 @@ module LoadScript = {
}
module CdnMeta = {
- let baseUrl = switch Node.Process.env->Dict.get("VERCEL") {
- | Some(_) => "https://cdn.rescript-lang.org"
- | None => "/playground-bundles"
- }
+ let baseUrl = "/playground-bundles"
let getCompilerUrl = (version): string => `${baseUrl}/${Semver.toString(version)}/compiler.js`
diff --git a/src/components/Footer.res b/src/components/Footer.res
index dc4c88fc5..d402614bc 100644
--- a/src/components/Footer.res
+++ b/src/components/Footer.res
@@ -23,22 +23,6 @@ let make = () => {
{React.string(`© ${copyrightYear} The ReScript Project`)}
-
- {React.string("Software and assets distribution powered by ")}
- {React.string("KeyCDN")}
- {React.string(".")}
-
-
-
-
-
-
}
-}
-
-module Res = {
- type res
-
- @send external revalidate: (res, string) => promise = "revalidate"
- @send external json: (res, {..}) => res = "json"
-
- module Status = {
- type t
- @send external make: (res, int) => t = "status"
- @send external send: (t, string) => res = "send"
- @send external json: (t, {..}) => res = "json"
- }
-}
-
-let handler = async (req: Req.req, res: Res.res) => {
- switch req.query->Dict.get("secret") {
- | Some(secret) =>
- switch Node.Process.env->Dict.get("NEXT_REVALIDATE_SECRET_TOKEN") {
- | Some(token) =>
- if secret !== token {
- res->Res.Status.make(401)->Res.Status.json({"message": "Invalid secret"})
- } else {
- try {
- let () = await res->Res.revalidate("/try")
- res->Res.json({"revalidated": true})
- } catch {
- | Exn.Error(_) => res->Res.Status.make(500)->Res.Status.send("Error revalidating")
- }
- }
- | None =>
- res
- ->Res.Status.make(500)
- ->Res.Status.send("Error revalidating, `NEXT_REVALIDATE_SECRET_TOKEN` not found")
- }
- | None =>
- res->Res.Status.make(500)->Res.Status.send("Error revalidating, param `secret` not found")
- }
-}
diff --git a/src/others/Revalidate.resi b/src/others/Revalidate.resi
deleted file mode 100644
index 694cd1958..000000000
--- a/src/others/Revalidate.resi
+++ /dev/null
@@ -1,7 +0,0 @@
-module Req: {
- type req
-}
-module Res: {
- type res
-}
-let handler: (Req.req, Res.res) => promise