Commit graph

18 commits

Author SHA1 Message Date
David Sanders
3d2a754531
chore: extend linting of code blocks in the docs (#40245)
* chore: extend linting of code blocks in the docs

* chore: combine lint:markdownlint and lint:markdown scripts
2023-11-21 16:50:08 +09:00
David Sanders
905aad9cb6
chore: type check JS in docs (#38423)
* build(deps): update @electron/lint-roller

* chore: type check JS in docs

* docs: add @ts-check and @ts-expect-error to code blocks

* chore: fix type check errors in docs

* chore: add ts-type to blocks
2023-06-05 16:26:26 +09:00
David Sanders
993d0337a7
docs: fix broken links (#36519)
* docs: fix broken links

* docs: change link to navigator.getUserMedia

Co-authored-by: Jeremy Rose <nornagon@nornagon.net>

* docs: fix link in examples.md

Co-authored-by: Jeremy Rose <nornagon@nornagon.net>
2022-12-05 13:18:57 -05:00
Jeremy Rose
6ad679f540
feat: webFrameMain.origin (#35438) 2022-08-31 17:40:57 -07:00
Jeremy Rose
6d859dcd7f
feat: add WebContents.ipc (#34959) 2022-08-03 16:55:12 -07:00
Will Anderson
4f99e3e46c
docs: fix did-frame-navigate example in webFrameMain docs (#34419)
docs: fix did-frame-navigate example in webFrameMain docs
2022-06-06 14:49:14 +09:00
Jeremy Rose
4fdf8584ed
docs: fix SCA and postMessage links in web-frame-main.md (#33415) 2022-03-24 13:12:47 -04:00
Milan Burda
e6b1d95a1c
docs: type names changed from wrapper to primitive (#31752) 2021-11-15 22:13:18 -06:00
Samuel Maddock
4d89174b41
feat: add 'dom-ready' event to WebFrameMain (#29290) 2021-09-01 15:21:15 -07:00
Samuel Attard
81795744cf
fix: ensure the typescript definitions only export correct value types (#28712)
* fix: ensure the typescript definitions only export correct value types

In typescript there are two main types of "types" you can export, value types (class, const) and definition types (type, interface).  The typescript compiler will let anything declared via const or class be used as a value.  Unfortunately we were exporting a bunch of things (see the diff) as class/const when they weren't actually exported values. This lead to typescript being happy but the runtime throwing errors (not something we want).

This change passes "exported-in" context through our docs, to the parser and then to the definitions generator to ensure we only mark things as exported in the ts defs that we actually export.

Fixes #22167

* chore: update typescript-defs

* chore: update typescript-defs

* chore: fix bad typescript in IPC test

* docs: test rendering of new syntax

* chore: update per feedback, use same syntax but with 'this is not exportedd' line
2021-06-15 13:50:31 -07:00
Samuel Maddock
43d27cc4d1
feat: add WebFrameMain.visibilityState (#28706)
* feat: add WebFrameMain.visibilityState

* docs: mention other page visibility APIs

* test: delay visibilityState check after hiding

* test: add waitForTrue to avoid flaky visibilityState test

* refactor: waitForTrue -> waitUntil
2021-04-22 12:00:58 -04:00
Keeley Hammond
84d0e827a3
chore: revert webFrameMain.executeJavaScriptInIsolatedWorld method (#27926) 2021-03-01 10:07:25 -05:00
Milan Burda
2be3d03630
feat: add webFrameMain.send() / webFrameMain.postMessage() (#26807) 2021-01-15 09:00:37 +09:00
Milan Burda
3d59aa5609
feat: add webFrameMain.executeJavaScriptInIsolatedWorld() (#26913) 2021-01-05 17:18:38 +09:00
Milan Burda
16c864a932
docs: webFrameMain.fromId() can return undefined (#27068)
* docs: webFrameMain.fromId() can return undefined

* docs: webFrameMain.fromId() can return undefined
2021-01-05 11:31:21 +09:00
Milan Burda
cec6378881
feat: add event.senderFrame property returning the originating webFrameMain (#26764) 2020-12-09 15:34:06 -08:00
Milan Burda
aa157c3f05
feat: add osProcessId / name properties to webFrameMain (#26093)
* feat: add osProcessId / name properties to webFrameMain

* Update docs/api/web-frame-main.md

Co-authored-by: Jeremy Rose <jeremya@chromium.org>

Co-authored-by: Jeremy Rose <jeremya@chromium.org>
2020-10-26 06:03:34 +03:00
Samuel Maddock
704d69a8f9
feat: add webFrameMain API to the main process (#25464) 2020-10-09 09:50:46 -07:00