diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 00:47:55 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 00:47:55 +0000 |
commit | 26a029d407be480d791972afb5975cf62c9360a6 (patch) | |
tree | f435a8308119effd964b339f76abb83a57c29483 /devtools/client/debugger/test/mochitest/examples/inline-preview.js | |
parent | Initial commit. (diff) | |
download | firefox-26a029d407be480d791972afb5975cf62c9360a6.tar.xz firefox-26a029d407be480d791972afb5975cf62c9360a6.zip |
Adding upstream version 124.0.1.upstream/124.0.1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'devtools/client/debugger/test/mochitest/examples/inline-preview.js')
-rw-r--r-- | devtools/client/debugger/test/mochitest/examples/inline-preview.js | 60 |
1 files changed, 60 insertions, 0 deletions
diff --git a/devtools/client/debugger/test/mochitest/examples/inline-preview.js b/devtools/client/debugger/test/mochitest/examples/inline-preview.js new file mode 100644 index 0000000000..dca40d03f1 --- /dev/null +++ b/devtools/client/debugger/test/mochitest/examples/inline-preview.js @@ -0,0 +1,60 @@ +function checkValues() { + const a = ""; + const b = false; + const c = undefined; + const d = null; + const e = []; + const f = {}; + const reg = /^\p{RGI_Emoji}$/v; + const obj = { + foo: 1, + }; + + let bs = []; + for (let i = 0; i <= 100; i++) { + bs.push({ a: 2, b: { c: 3 } }); + } + debugger; +} + +function columnWise() { + let a = "a"; + let b = "b"; + let c = "c"; + console.log(c, a, b); + debugger; +} + +function objectProperties() { + const obj = { hello: "world", a: { b: "c" } }; + console.log(obj.hello); + console.log(obj.a.b); + debugger; +} + +function classProperties() { + class Foo { + x = 1; + #privateVar = 2; + #privateMethod() { + return this.#privateVar; + } + breakFn() { + let i = this.x * this.#privateVar; + const self = this; + debugger; + } + } + const foo = new Foo(); + foo.breakFn(); +} + +function btnClick() { + const btn = document.querySelector("button"); + debugger; + btn.click(); +} + +function onBtnClick(event) { + debugger; +} |