diff --git a/TS.fsx b/TS.fsx index 411f75660..45a18403c 100644 --- a/TS.fsx +++ b/TS.fsx @@ -234,7 +234,7 @@ let EmitProperties flavor prefix (emitScope: EmitScope) (i: Browser.Interface)= | None -> () getAddedItems ItemKind.Property flavor - |> Array.filter (matchInterface i.Name) + |> Array.filter (fun addedItem -> (matchInterface i.Name addedItem) && (prefix <> "declare var " || not(OptionCheckValue false addedItem.ExposeGlobally))) |> Array.iter emitPropertyFromJson let EmitMethods flavor prefix (emitScope: EmitScope) (i: Browser.Interface) = diff --git a/inputfiles/sample.json b/inputfiles/sample.json index ed0e2ef43..8103e7515 100644 --- a/inputfiles/sample.json +++ b/inputfiles/sample.json @@ -2,6 +2,7 @@ { "kind": "property", "interface": "Window", + "exposeGlobally": false, "name": "URL", "type": "URL" },