From 895193188caffb0644889aca3a614c3b65ac81d5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Paul=20Tsnobiladz=C3=A9?= Date: Thu, 13 Mar 2025 09:30:24 +0100 Subject: [PATCH] deprecate unsafe host-specific bindings from stdlib --- CHANGELOG.md | 1 + runtime/Stdlib.res | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e93d38e7e6..807dfc88ba 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -32,6 +32,7 @@ - Deprecate JSON.Classify.classify. https://github.com/rescript-lang/rescript/pull/7315 - Hide stdlib modules in output. https://github.com/rescript-lang/rescript/pull/7305 +- Deprecate unsafe host-specific bindings from stdlib. https://github.com/rescript-lang/rescript/pull/7334 #### :bug: Bug fix diff --git a/runtime/Stdlib.res b/runtime/Stdlib.res index d376f49359..743a4a651c 100644 --- a/runtime/Stdlib.res +++ b/runtime/Stdlib.res @@ -53,8 +53,8 @@ type null<+'a> = Primitive_js_extern.null<'a> type undefined<+'a> = Primitive_js_extern.undefined<'a> type nullable<+'a> = Primitive_js_extern.nullable<'a> -@val external window: Dom.window = "window" -@val external document: Dom.document = "document" +@deprecated("Use rescript-webapi instead") @val external window: Dom.window = "window" +@deprecated("Use rescript-webapi instead") @val external document: Dom.document = "document" @val external globalThis: {..} = "globalThis" /**