diff --git a/src/GreenfinityNext_Cache.res b/src/GreenfinityNext_Cache.res index 08a29d1..bc9c0ea 100644 --- a/src/GreenfinityNext_Cache.res +++ b/src/GreenfinityNext_Cache.res @@ -4,7 +4,19 @@ type cacheType = @module("next/cache") external revalidatePath: (string, ~_type: cacheType=?) => unit = "revalidatePath" + +type revalidateProfileOptions = {expire?: int} +@unboxed +type revalidateProfile = | @as("max") Max | Options(revalidateProfileOptions) + +@module("next/cache") +external revalidateTag: (string, ~profile: revalidateProfile) => unit = "revalidateTag" + +@module("next/cache") +external updateTag: string => unit = "updateTag" + @module("next/cache") external cacheTag: string => unit = "cacheTag" + @module("next/cache") external cacheLife: string => unit = "cacheLife" /**