diff --git a/apps/web/src/__generated__/questions/coding/list.en-US.json b/apps/web/src/__generated__/questions/coding/list.en-US.json index e18dd7fe3..63068fb14 100644 --- a/apps/web/src/__generated__/questions/coding/list.en-US.json +++ b/apps/web/src/__generated__/questions/coding/list.en-US.json @@ -1,6 +1,6 @@ [ { - "access": "free", + "access": "premium", "author": "yangshun", "companies": [], "created": 1671580800, @@ -36,7 +36,9 @@ "slug": "accordion", "subtitle": null, "title": "Accordion", - "topics": [] + "topics": [ + "a11y" + ] }, { "access": "premium", @@ -74,7 +76,9 @@ "slug": "accordion-ii", "subtitle": null, "title": "Accordion II", - "topics": [] + "topics": [ + "a11y" + ] }, { "access": "premium", @@ -106,7 +110,9 @@ "slug": "accordion-iii", "subtitle": null, "title": "Accordion III", - "topics": [] + "topics": [ + "a11y" + ] }, { "access": "premium", @@ -159,7 +165,10 @@ "slug": "analog-clock", "subtitle": null, "title": "Analog Clock", - "topics": [] + "topics": [ + "a11y", + "async" + ] }, { "access": "premium", @@ -405,7 +414,9 @@ "slug": "auth-code-input", "subtitle": null, "title": "Auth Code Input", - "topics": [] + "topics": [ + "a11y" + ] }, { "access": "premium", @@ -427,9 +438,7 @@ "js", "ts" ], - "nextQuestions": [ - "" - ], + "nextQuestions": [], "published": true, "ranking": 100, "similarQuestions": [ @@ -439,7 +448,9 @@ "slug": "backbone-model", "subtitle": null, "title": "Backbone Model", - "topics": [] + "topics": [ + "oop" + ] }, { "access": "free", @@ -576,7 +587,9 @@ "slug": "camel-case-keys", "subtitle": null, "title": "Camel Case Keys", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -605,7 +618,9 @@ "slug": "cancellable-interval", "subtitle": null, "title": "Cancellable Interval", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -634,7 +649,9 @@ "slug": "cancellable-timeout", "subtitle": null, "title": "Cancellable Timeout", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -966,7 +983,9 @@ "slug": "contact-form", "subtitle": null, "title": "Contact Form", - "topics": [] + "topics": [ + "a11y" + ] }, { "access": "free", @@ -1176,7 +1195,9 @@ "slug": "cycle", "subtitle": null, "title": "Cycle", - "topics": [] + "topics": [ + "closure" + ] }, { "access": "premium", @@ -1416,7 +1437,9 @@ "slug": "debounce", "subtitle": null, "title": "Debounce", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -1454,7 +1477,9 @@ "slug": "debounce-ii", "subtitle": null, "title": "Debounce II", - "topics": [] + "topics": [ + "async" + ] }, { "access": "free", @@ -1490,7 +1515,9 @@ "slug": "deep-clone", "subtitle": null, "title": "Deep Clone", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -1519,7 +1546,9 @@ "slug": "deep-clone-ii", "subtitle": null, "title": "Deep Clone II", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -1551,7 +1580,9 @@ "slug": "deep-equal", "subtitle": null, "title": "Deep Equal", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -1581,7 +1612,9 @@ "slug": "deep-map", "subtitle": null, "title": "Deep Map", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -1610,7 +1643,9 @@ "slug": "deep-merge", "subtitle": null, "title": "Deep Merge", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -1639,7 +1674,9 @@ "slug": "deep-omit", "subtitle": null, "title": "Deep Omit", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "free", @@ -1713,7 +1750,9 @@ "slug": "dice-roller", "subtitle": null, "title": "Dice Roller", - "topics": [] + "topics": [ + "a11y" + ] }, { "access": "premium", @@ -1795,7 +1834,10 @@ "slug": "digital-clock", "subtitle": null, "title": "Digital Clock", - "topics": [] + "topics": [ + "a11y", + "async" + ] }, { "access": "premium", @@ -1890,7 +1932,9 @@ "slug": "event-emitter", "subtitle": null, "title": "Event Emitter", - "topics": [] + "topics": [ + "oop" + ] }, { "access": "premium", @@ -1926,7 +1970,9 @@ "slug": "event-emitter-ii", "subtitle": null, "title": "Event Emitter II", - "topics": [] + "topics": [ + "oop" + ] }, { "access": "free", @@ -1968,7 +2014,9 @@ "slug": "file-explorer", "subtitle": null, "title": "File Explorer", - "topics": [] + "topics": [ + "a11y" + ] }, { "access": "premium", @@ -2038,7 +2086,7 @@ "js" ], "nextQuestions": [ - "file-explorer-iii" + "nested-checkboxes" ], "published": true, "ranking": 100, @@ -2172,7 +2220,9 @@ "slug": "flatten", "subtitle": null, "title": "Flatten", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -2190,6 +2240,10 @@ "framework": "react", "href": "/questions/user-interface/flight-booker/react" }, + { + "framework": "vanilla", + "href": "/questions/user-interface/flight-booker/vanilla" + }, { "framework": "angular", "href": "/questions/user-interface/flight-booker/angular" @@ -2216,7 +2270,9 @@ "slug": "flight-booker", "subtitle": null, "title": "Flight Booker", - "topics": [] + "topics": [ + "a11y" + ] }, { "access": "premium", @@ -2450,7 +2506,9 @@ "slug": "get", "subtitle": null, "title": "Get", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -2486,7 +2544,9 @@ "slug": "get-elements-by-class-name", "subtitle": null, "title": "getElementsByClassName", - "topics": [] + "topics": [ + "web-api" + ] }, { "access": "premium", @@ -2520,7 +2580,9 @@ "slug": "get-elements-by-style", "subtitle": null, "title": "getElementsByStyle", - "topics": [] + "topics": [ + "web-api" + ] }, { "access": "premium", @@ -2553,7 +2615,9 @@ "slug": "get-elements-by-tag-name", "subtitle": null, "title": "getElementsByTagName", - "topics": [] + "topics": [ + "web-api" + ] }, { "access": "premium", @@ -2587,7 +2651,9 @@ "slug": "get-elements-by-tag-name-hierarchy", "subtitle": null, "title": "getElementsByTagNameHierarchy", - "topics": [] + "topics": [ + "web-api" + ] }, { "access": "premium", @@ -2634,7 +2700,10 @@ "slug": "grid-lights", "subtitle": null, "title": "Grid Lights", - "topics": [] + "topics": [ + "a11y", + "async" + ] }, { "access": "premium", @@ -2780,7 +2849,9 @@ "slug": "html-serializer", "subtitle": null, "title": "HTML Serializer", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -2810,7 +2881,11 @@ "slug": "identical-dom-trees", "subtitle": null, "title": "Identical DOM Trees", - "topics": [] + "topics": [ + "recursion", + "tree", + "web-api" + ] }, { "access": "free", @@ -2854,7 +2929,9 @@ "slug": "image-carousel", "subtitle": null, "title": "Image Carousel", - "topics": [] + "topics": [ + "a11y" + ] }, { "access": "premium", @@ -2897,7 +2974,9 @@ "slug": "image-carousel-ii", "subtitle": null, "title": "Image Carousel II", - "topics": [] + "topics": [ + "a11y" + ] }, { "access": "premium", @@ -3167,7 +3246,9 @@ "slug": "job-board", "subtitle": null, "title": "Job Board", - "topics": [] + "topics": [ + "networking" + ] }, { "access": "premium", @@ -3198,7 +3279,10 @@ "slug": "jquery-class-manipulation", "subtitle": null, "title": "jQuery Class Manipulation", - "topics": [] + "topics": [ + "oop", + "web-api" + ] }, { "access": "premium", @@ -3229,7 +3313,10 @@ "slug": "jquery-css", "subtitle": null, "title": "jQuery.css", - "topics": [] + "topics": [ + "oop", + "web-api" + ] }, { "access": "premium", @@ -3262,7 +3349,9 @@ "slug": "json-stringify", "subtitle": null, "title": "JSON.stringify", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -3293,7 +3382,9 @@ "slug": "json-stringify-ii", "subtitle": null, "title": "JSON.stringify II", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -3340,7 +3431,10 @@ "slug": "like-button", "subtitle": null, "title": "Like Button", - "topics": [] + "topics": [ + "async", + "networking" + ] }, { "access": "premium", @@ -3431,7 +3525,9 @@ "slug": "make-counter", "subtitle": null, "title": "Make Counter", - "topics": [] + "topics": [ + "closure" + ] }, { "access": "premium", @@ -3463,7 +3559,9 @@ "slug": "make-counter-ii", "subtitle": null, "title": "Make Counter II", - "topics": [] + "topics": [ + "closure" + ] }, { "access": "premium", @@ -3498,7 +3596,9 @@ "slug": "map-async", "subtitle": null, "title": "Map Async", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -3531,7 +3631,9 @@ "slug": "map-async-limit", "subtitle": null, "title": "Map Async Limit", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -3790,7 +3892,9 @@ "slug": "modal-dialog", "subtitle": null, "title": "Modal Dialog", - "topics": [] + "topics": [ + "a11y" + ] }, { "access": "premium", @@ -3827,7 +3931,9 @@ "slug": "modal-dialog-ii", "subtitle": null, "title": "Modal Dialog II", - "topics": [] + "topics": [ + "a11y" + ] }, { "access": "premium", @@ -3863,7 +3969,9 @@ "slug": "modal-dialog-iii", "subtitle": null, "title": "Modal Dialog III", - "topics": [] + "topics": [ + "a11y" + ] }, { "access": "premium", @@ -3897,7 +4005,9 @@ "slug": "modal-dialog-iv", "subtitle": null, "title": "Modal Dialog IV", - "topics": [] + "topics": [ + "a11y" + ] }, { "access": "free", @@ -4075,7 +4185,9 @@ "slug": "once", "subtitle": null, "title": "Once", - "topics": [] + "topics": [ + "closure" + ] }, { "access": "premium", @@ -4120,7 +4232,9 @@ "slug": "pixel-art", "subtitle": null, "title": "Pixel Art", - "topics": [] + "topics": [ + "a11y" + ] }, { "access": "premium", @@ -4202,7 +4316,9 @@ "slug": "progress-bars", "subtitle": null, "title": "Progress Bars", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -4239,7 +4355,9 @@ "slug": "progress-bars-ii", "subtitle": null, "title": "Progress Bars II", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -4276,7 +4394,9 @@ "slug": "progress-bars-iii", "subtitle": null, "title": "Progress Bars III", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -4311,7 +4431,9 @@ "slug": "progress-bars-iv", "subtitle": null, "title": "Progress Bars IV", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -4343,7 +4465,9 @@ "slug": "promise-merge", "subtitle": null, "title": "Promise Merge", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -4370,7 +4494,9 @@ "slug": "promise-timeout", "subtitle": null, "title": "Promise Timeout", - "topics": [] + "topics": [ + "async" + ] }, { "access": "free", @@ -4411,7 +4537,9 @@ "slug": "promise-all", "subtitle": null, "title": "Promise.all", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -4442,7 +4570,9 @@ "slug": "promise-all-settled", "subtitle": null, "title": "Promise.allSettled", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -4473,7 +4603,9 @@ "slug": "promise-any", "subtitle": null, "title": "Promise.any", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -4506,7 +4638,9 @@ "slug": "promise-race", "subtitle": null, "title": "Promise.race", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -4539,7 +4673,9 @@ "slug": "promise-reject", "subtitle": null, "title": "Promise.reject", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -4572,7 +4708,9 @@ "slug": "promise-resolve", "subtitle": null, "title": "Promise.resolve", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -4602,7 +4740,9 @@ "slug": "promise-with-resolvers", "subtitle": null, "title": "Promise.withResolvers", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -4633,7 +4773,9 @@ "slug": "promisify", "subtitle": null, "title": "Promisify", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -4660,7 +4802,9 @@ "slug": "promisify-ii", "subtitle": null, "title": "Promisify II", - "topics": [] + "topics": [ + "async" + ] }, { "access": "free", @@ -4811,7 +4955,10 @@ "slug": "resumable-interval", "subtitle": null, "title": "Resumable Interval", - "topics": [] + "topics": [ + "async", + "closure" + ] }, { "access": "premium", @@ -4993,7 +5140,9 @@ "slug": "sleep", "subtitle": null, "title": "Sleep", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -5023,7 +5172,9 @@ "slug": "squash-object", "subtitle": null, "title": "Squash Object", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "free", @@ -5159,7 +5310,9 @@ "slug": "stopwatch", "subtitle": null, "title": "Stopwatch", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -5191,7 +5344,9 @@ "slug": "sum", "subtitle": null, "title": "Sum", - "topics": [] + "topics": [ + "closure" + ] }, { "access": "premium", @@ -5221,7 +5376,11 @@ "slug": "table-of-contents", "subtitle": null, "title": "Table of Contents", - "topics": [] + "topics": [ + "recursion", + "tree", + "web-api" + ] }, { "access": "free", @@ -5271,7 +5430,9 @@ "slug": "tabs", "subtitle": null, "title": "Tabs", - "topics": [] + "topics": [ + "a11y" + ] }, { "access": "premium", @@ -5321,7 +5482,9 @@ "slug": "tabs-ii", "subtitle": null, "title": "Tabs II", - "topics": [] + "topics": [ + "a11y" + ] }, { "access": "premium", @@ -5364,7 +5527,9 @@ "slug": "tabs-iii", "subtitle": null, "title": "Tabs III", - "topics": [] + "topics": [ + "a11y" + ] }, { "access": "premium", @@ -5512,7 +5677,9 @@ "slug": "throttle", "subtitle": null, "title": "Throttle", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -5564,7 +5731,9 @@ "slug": "tic-tac-toe", "subtitle": null, "title": "Tic-tac-toe", - "topics": [] + "topics": [ + "a11y" + ] }, { "access": "premium", @@ -5614,7 +5783,9 @@ "slug": "tic-tac-toe-ii", "subtitle": null, "title": "Tic-tac-toe II", - "topics": [] + "topics": [ + "a11y" + ] }, { "access": "free", @@ -5755,7 +5926,9 @@ "slug": "traffic-light", "subtitle": null, "title": "Traffic Light", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -5881,7 +6054,9 @@ "slug": "turtle", "subtitle": null, "title": "Turtle", - "topics": [] + "topics": [ + "oop" + ] }, { "access": "premium", diff --git a/apps/web/src/__generated__/questions/javascript/backbone-model/en-US.json b/apps/web/src/__generated__/questions/javascript/backbone-model/en-US.json index e2e3920c7..51234ba34 100644 --- a/apps/web/src/__generated__/questions/javascript/backbone-model/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/backbone-model/en-US.json @@ -28,9 +28,7 @@ "js", "ts" ], - "nextQuestions": [ - "" - ], + "nextQuestions": [], "published": true, "ranking": 100, "similarQuestions": [ @@ -40,7 +38,9 @@ "slug": "backbone-model", "subtitle": null, "title": "Backbone Model", - "topics": [] + "topics": [ + "oop" + ] }, "skeleton": { "js": "// You are free to use alternative approaches of\n// defining BackboneModel as long as the\n// default export can be instantiated.\nexport default class BackboneModel {\n /**\n * @param {Object} initialValues\n * @returns BackboneModel\n */\n constructor(initialValues) {\n throw 'Not implemented!';\n }\n\n /**\n * Get the value of a specific attribute.\n * @param {string} attribute - The attribute name.\n * @returns {any | undefined} The value of the attribute.\n */\n get(attribute) {\n throw 'Not implemented!';\n }\n\n /**\n * Set the value of a specific attribute.\n * @param {string} attribute - The attribute name.\n * @param {any} value - The value to set for the attribute.\n */\n set(attribute, value) {\n throw 'Not implemented!';\n }\n\n /**\n * Check if the model has a specific attribute.\n * @param {string} attribute - The attribute name.\n * @returns {boolean} `true` if the model has the attribute, `false` otherwise.\n */\n has(attribute) {\n throw 'Not implemented!';\n }\n\n /**\n * Unset a specific attribute.\n * @param {string} attribute - The attribute name to unset.\n */\n unset(attribute) {\n throw 'Not implemented!';\n }\n\n /**\n * Register an event listener for changes to a specific attribute.\n * @param {string} eventName - The event name.\n * @param {string} attribute - The attribute name to listen for changes.\n * @param {Function} callback - The callback function to be executed on the event.\n * @param {any} [context] - The context in which to execute the callback.\n */\n on(eventName, attribute, callback, context) {\n throw 'Not implemented!';\n }\n\n /**\n * Remove an event listener for changes to a specific attribute.\n * @param {string} eventName - The event name.\n * @param {string} attribute - The attribute name to stop listening for changes.\n * @param {Function} callback - The callback function to remove.\n */\n off(eventName, attribute, callback) {\n throw 'Not implemented!';\n }\n}", diff --git a/apps/web/src/__generated__/questions/javascript/camel-case-keys/en-US.json b/apps/web/src/__generated__/questions/javascript/camel-case-keys/en-US.json index f5450d13a..41e59e467 100644 --- a/apps/web/src/__generated__/questions/javascript/camel-case-keys/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/camel-case-keys/en-US.json @@ -36,7 +36,9 @@ "slug": "camel-case-keys", "subtitle": null, "title": "Camel Case Keys", - "topics": [] + "topics": [ + "recursion" + ] }, "skeleton": { "js": "/**\n * @param Object\n * @return Object\n */\nexport default function camelCaseKeys(object) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/cancellable-interval/en-US.json b/apps/web/src/__generated__/questions/javascript/cancellable-interval/en-US.json index 644f8b780..01ff1e076 100644 --- a/apps/web/src/__generated__/questions/javascript/cancellable-interval/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/cancellable-interval/en-US.json @@ -35,7 +35,9 @@ "slug": "cancellable-interval", "subtitle": null, "title": "Cancellable Interval", - "topics": [] + "topics": [ + "async" + ] }, "skeleton": { "js": "/**\n * @param {Function} callback\n * @param {number} delay\n * @param {...any} args\n * @returns {Function}\n */\nexport default function setCancellableInterval(callback, delay, ...args) {\n throw 'Not implemented';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/cancellable-timeout/en-US.json b/apps/web/src/__generated__/questions/javascript/cancellable-timeout/en-US.json index 931b7e135..ebca9af4c 100644 --- a/apps/web/src/__generated__/questions/javascript/cancellable-timeout/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/cancellable-timeout/en-US.json @@ -35,7 +35,9 @@ "slug": "cancellable-timeout", "subtitle": null, "title": "Cancellable Timeout", - "topics": [] + "topics": [ + "async" + ] }, "skeleton": { "js": "/**\n * @param {Function} callback\n * @param {number} delay\n * @param {...any} args\n * @returns {Function}\n */\nexport default function setCancellableTimeout(callback, delay, ...args) {\n throw 'Not implemented';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/cycle/en-US.json b/apps/web/src/__generated__/questions/javascript/cycle/en-US.json index 92ea274cb..438cb89dd 100644 --- a/apps/web/src/__generated__/questions/javascript/cycle/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/cycle/en-US.json @@ -33,7 +33,9 @@ "slug": "cycle", "subtitle": null, "title": "Cycle", - "topics": [] + "topics": [ + "closure" + ] }, "skeleton": { "js": "/**\n * @template T\n * @param {...T} values\n *\n * @returns () => T\n */\nexport default function cycle(...values) {\n throw 'Not implemented';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/debounce-ii/en-US.json b/apps/web/src/__generated__/questions/javascript/debounce-ii/en-US.json index e638ab667..89b8514af 100644 --- a/apps/web/src/__generated__/questions/javascript/debounce-ii/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/debounce-ii/en-US.json @@ -44,7 +44,9 @@ "slug": "debounce-ii", "subtitle": null, "title": "Debounce II", - "topics": [] + "topics": [ + "async" + ] }, "skeleton": { "js": "/**\n * @param {Function} func\n * @param {number} wait\n * @return {Function}\n */\nexport default function debounce(func, wait) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/debounce/en-US.json b/apps/web/src/__generated__/questions/javascript/debounce/en-US.json index 904906ff8..664d89cc4 100644 --- a/apps/web/src/__generated__/questions/javascript/debounce/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/debounce/en-US.json @@ -45,7 +45,9 @@ "slug": "debounce", "subtitle": null, "title": "Debounce", - "topics": [] + "topics": [ + "async" + ] }, "skeleton": { "js": "/**\n * @param {Function} func\n * @param {number} wait\n * @return {Function}\n */\nexport default function debounce(func, wait) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/deep-clone-ii/en-US.json b/apps/web/src/__generated__/questions/javascript/deep-clone-ii/en-US.json index 227f865b9..41e40a529 100644 --- a/apps/web/src/__generated__/questions/javascript/deep-clone-ii/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/deep-clone-ii/en-US.json @@ -35,7 +35,9 @@ "slug": "deep-clone-ii", "subtitle": null, "title": "Deep Clone II", - "topics": [] + "topics": [ + "recursion" + ] }, "skeleton": { "js": "/**\n * @template T\n * @param {T} value\n * @return {T}\n */\nexport default function deepClone(value) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/deep-clone/en-US.json b/apps/web/src/__generated__/questions/javascript/deep-clone/en-US.json index 5b8318c4f..67d86abf7 100644 --- a/apps/web/src/__generated__/questions/javascript/deep-clone/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/deep-clone/en-US.json @@ -42,7 +42,9 @@ "slug": "deep-clone", "subtitle": null, "title": "Deep Clone", - "topics": [] + "topics": [ + "recursion" + ] }, "skeleton": { "js": "/**\n * @template T\n * @param {T} value\n * @return {T}\n */\nexport default function deepClone(value) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/deep-equal/en-US.json b/apps/web/src/__generated__/questions/javascript/deep-equal/en-US.json index 7bee36782..5d51a27ea 100644 --- a/apps/web/src/__generated__/questions/javascript/deep-equal/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/deep-equal/en-US.json @@ -38,7 +38,9 @@ "slug": "deep-equal", "subtitle": null, "title": "Deep Equal", - "topics": [] + "topics": [ + "recursion" + ] }, "skeleton": { "js": "/**\n * @param {*} valueA\n * @param {*} valueB\n * @return {boolean}\n */\nexport default function deepEqual(valueA, valueB) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/deep-map/en-US.json b/apps/web/src/__generated__/questions/javascript/deep-map/en-US.json index 038a0efdb..ad9451105 100644 --- a/apps/web/src/__generated__/questions/javascript/deep-map/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/deep-map/en-US.json @@ -36,7 +36,9 @@ "slug": "deep-map", "subtitle": null, "title": "Deep Map", - "topics": [] + "topics": [ + "recursion" + ] }, "skeleton": { "js": "/**\n * @param {any} value\n * @param {Function} fn\n * @returns any\n */\nexport default function deepMap(value, fn) {\n throw 'Not implemented';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/deep-merge/en-US.json b/apps/web/src/__generated__/questions/javascript/deep-merge/en-US.json index f4a28eca3..577a997f6 100644 --- a/apps/web/src/__generated__/questions/javascript/deep-merge/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/deep-merge/en-US.json @@ -35,7 +35,9 @@ "slug": "deep-merge", "subtitle": null, "title": "Deep Merge", - "topics": [] + "topics": [ + "recursion" + ] }, "skeleton": { "js": "/**\n * @param {Object|Array} valA\n * @param {Object|Array} valB\n * @returns Object|Array\n */\nexport default function deepMerge(valA, valB) {\n throw 'Not implemented';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/deep-omit/en-US.json b/apps/web/src/__generated__/questions/javascript/deep-omit/en-US.json index 7b54a0fb8..64868bfe2 100644 --- a/apps/web/src/__generated__/questions/javascript/deep-omit/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/deep-omit/en-US.json @@ -35,7 +35,9 @@ "slug": "deep-omit", "subtitle": null, "title": "Deep Omit", - "topics": [] + "topics": [ + "recursion" + ] }, "skeleton": { "js": "/**\n * @param {any} val\n * @param {Array} keys\n * @returns any\n */\nexport default function deepOmit(val, keys) {\n throw 'Not implemented';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/event-emitter-ii/en-US.json b/apps/web/src/__generated__/questions/javascript/event-emitter-ii/en-US.json index 8b3f6c548..c8b576e65 100644 --- a/apps/web/src/__generated__/questions/javascript/event-emitter-ii/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/event-emitter-ii/en-US.json @@ -42,7 +42,9 @@ "slug": "event-emitter-ii", "subtitle": null, "title": "Event Emitter II", - "topics": [] + "topics": [ + "oop" + ] }, "skeleton": { "js": "// You are free to use alternative approaches of\n// instantiating the EventEmitter as long as the\n// default export is correct.\nexport default class EventEmitter {\n constructor() {\n throw 'Not implemented!';\n }\n\n /**\n * @param {string} eventName\n * @param {Function} listener\n * @returns {{off: Function}}\n */\n on(eventName, listener) {\n throw 'Not implemented!';\n }\n\n /**\n * @param {string} eventName\n * @param {...any} args\n * @returns boolean\n */\n emit(eventName, ...args) {\n throw 'Not implemented!';\n }\n}", diff --git a/apps/web/src/__generated__/questions/javascript/event-emitter/en-US.json b/apps/web/src/__generated__/questions/javascript/event-emitter/en-US.json index b1c31a1ac..b9541704d 100644 --- a/apps/web/src/__generated__/questions/javascript/event-emitter/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/event-emitter/en-US.json @@ -43,7 +43,9 @@ "slug": "event-emitter", "subtitle": null, "title": "Event Emitter", - "topics": [] + "topics": [ + "oop" + ] }, "skeleton": { "js": "// You are free to use alternative approaches of\n// instantiating the EventEmitter as long as the\n// default export is correct.\n\nexport default class EventEmitter {\n constructor() {\n throw 'Not implemented!';\n }\n\n /**\n * @param {string} eventName\n * @param {Function} listener\n * @returns {EventEmitter}\n */\n on(eventName, listener) {\n throw 'Not implemented!';\n }\n\n /**\n * @param {string} eventName\n * @param {Function} listener\n * @returns {EventEmitter}\n */\n off(eventName, listener) {\n throw 'Not implemented!';\n }\n\n /**\n * @param {string} eventName\n * @param {...any} args\n * @returns {boolean}\n */\n emit(eventName, ...args) {\n throw 'Not implemented!';\n }\n}", diff --git a/apps/web/src/__generated__/questions/javascript/flatten/en-US.json b/apps/web/src/__generated__/questions/javascript/flatten/en-US.json index 84867dcda..95dba9b00 100644 --- a/apps/web/src/__generated__/questions/javascript/flatten/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/flatten/en-US.json @@ -47,7 +47,9 @@ "slug": "flatten", "subtitle": null, "title": "Flatten", - "topics": [] + "topics": [ + "recursion" + ] }, "skeleton": { "js": "/**\n * @param {Array<*|Array>} value\n * @return {Array}\n */\nexport default function flatten(value) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/get-elements-by-class-name/en-US.json b/apps/web/src/__generated__/questions/javascript/get-elements-by-class-name/en-US.json index 2d86c9428..92337c390 100644 --- a/apps/web/src/__generated__/questions/javascript/get-elements-by-class-name/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/get-elements-by-class-name/en-US.json @@ -42,7 +42,9 @@ "slug": "get-elements-by-class-name", "subtitle": null, "title": "getElementsByClassName", - "topics": [] + "topics": [ + "web-api" + ] }, "skeleton": { "js": "/**\n * @param {Element} element\n * @param {string} classNames\n * @return {Array}\n */\nexport default function getElementsByClassName(element, classNames) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/get-elements-by-style/en-US.json b/apps/web/src/__generated__/questions/javascript/get-elements-by-style/en-US.json index e37740f77..033312264 100644 --- a/apps/web/src/__generated__/questions/javascript/get-elements-by-style/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/get-elements-by-style/en-US.json @@ -40,7 +40,9 @@ "slug": "get-elements-by-style", "subtitle": null, "title": "getElementsByStyle", - "topics": [] + "topics": [ + "web-api" + ] }, "skeleton": { "js": "/**\n * @param {Element} element\n * @param {string} property\n * @param {string} value\n * @return {Array}\n */\nexport default function getElementsByStyle(element, property, value) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/get-elements-by-tag-name-hierarchy/en-US.json b/apps/web/src/__generated__/questions/javascript/get-elements-by-tag-name-hierarchy/en-US.json index 3170754dd..0f4db2c5d 100644 --- a/apps/web/src/__generated__/questions/javascript/get-elements-by-tag-name-hierarchy/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/get-elements-by-tag-name-hierarchy/en-US.json @@ -40,7 +40,9 @@ "slug": "get-elements-by-tag-name-hierarchy", "subtitle": null, "title": "getElementsByTagNameHierarchy", - "topics": [] + "topics": [ + "web-api" + ] }, "skeleton": { "js": "/**\n * @param {Document} document\n * @param {string} tagNames\n * @return {Array}\n */\nexport default function getElementsByTagNameHierarchy(document, tagNames) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/get-elements-by-tag-name/en-US.json b/apps/web/src/__generated__/questions/javascript/get-elements-by-tag-name/en-US.json index e63cb1821..93bbac867 100644 --- a/apps/web/src/__generated__/questions/javascript/get-elements-by-tag-name/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/get-elements-by-tag-name/en-US.json @@ -39,7 +39,9 @@ "slug": "get-elements-by-tag-name", "subtitle": null, "title": "getElementsByTagName", - "topics": [] + "topics": [ + "web-api" + ] }, "skeleton": { "js": "/**\n * @param {Element} el\n * @param {string} tagName\n * @return {Array}\n */\nexport default function getElementsByTagName(el, tagName) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/get/en-US.json b/apps/web/src/__generated__/questions/javascript/get/en-US.json index 8fcd64309..72f4495cd 100644 --- a/apps/web/src/__generated__/questions/javascript/get/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/get/en-US.json @@ -37,7 +37,9 @@ "slug": "get", "subtitle": null, "title": "Get", - "topics": [] + "topics": [ + "recursion" + ] }, "skeleton": { "js": "/**\n * @param {Object} objectParam\n * @param {string|Array} pathParam\n * @param {*} [defaultValue]\n * @return {*}\n */\nexport default function get(objectParam, pathParam, defaultValue) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/html-serializer/en-US.json b/apps/web/src/__generated__/questions/javascript/html-serializer/en-US.json index 3143266af..edbc1b6a2 100644 --- a/apps/web/src/__generated__/questions/javascript/html-serializer/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/html-serializer/en-US.json @@ -38,7 +38,9 @@ "slug": "html-serializer", "subtitle": null, "title": "HTML Serializer", - "topics": [] + "topics": [ + "recursion" + ] }, "skeleton": { "js": "/**\n * @param {Object} element\n * @return {string}\n */\nexport default function serializeHTML(element) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/identical-dom-trees/en-US.json b/apps/web/src/__generated__/questions/javascript/identical-dom-trees/en-US.json index bfa712f81..d74e1bb90 100644 --- a/apps/web/src/__generated__/questions/javascript/identical-dom-trees/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/identical-dom-trees/en-US.json @@ -36,7 +36,11 @@ "slug": "identical-dom-trees", "subtitle": null, "title": "Identical DOM Trees", - "topics": [] + "topics": [ + "recursion", + "tree", + "web-api" + ] }, "skeleton": { "js": "/**\n * @param {Node} nodeA\n * @param {Node} nodeB\n * @return {boolean}\n */\nexport default function identicalDOMTrees(nodeA, nodeB) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/jquery-class-manipulation/en-US.json b/apps/web/src/__generated__/questions/javascript/jquery-class-manipulation/en-US.json index 24baacf4a..4c9b3f08b 100644 --- a/apps/web/src/__generated__/questions/javascript/jquery-class-manipulation/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/jquery-class-manipulation/en-US.json @@ -37,7 +37,10 @@ "slug": "jquery-class-manipulation", "subtitle": null, "title": "jQuery Class Manipulation", - "topics": [] + "topics": [ + "oop", + "web-api" + ] }, "skeleton": { "js": "/**\n * @param {string} selector\n * @return {{toggleClass: Function, addClass: Function, removeClass: Function}}\n */\nexport default function $(selector) {\n const element = document.querySelector(selector);\n\n return {\n /**\n * @param {string} className\n * @param {boolean} [state]\n * @return {Object|void}\n */\n toggleClass: function (className, state) {\n throw 'Not implemented!';\n },\n /**\n * @param {string} className\n * @return {Object}\n */\n addClass: function (className) {\n throw 'Not implemented!';\n },\n /**\n * @param {string} className\n * @return {Object}\n */\n removeClass: function (className) {\n throw 'Not implemented!';\n },\n };\n}", diff --git a/apps/web/src/__generated__/questions/javascript/jquery-css/en-US.json b/apps/web/src/__generated__/questions/javascript/jquery-css/en-US.json index 4341577ab..5a9d8dfd8 100644 --- a/apps/web/src/__generated__/questions/javascript/jquery-css/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/jquery-css/en-US.json @@ -37,7 +37,10 @@ "slug": "jquery-css", "subtitle": null, "title": "jQuery.css", - "topics": [] + "topics": [ + "oop", + "web-api" + ] }, "skeleton": { "js": "/**\n * @param {string} selector\n * @return {{css: Function}}\n */\nexport default function $(selector) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/json-stringify-ii/en-US.json b/apps/web/src/__generated__/questions/javascript/json-stringify-ii/en-US.json index 2fb32a6e9..762eaea38 100644 --- a/apps/web/src/__generated__/questions/javascript/json-stringify-ii/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/json-stringify-ii/en-US.json @@ -37,7 +37,9 @@ "slug": "json-stringify-ii", "subtitle": null, "title": "JSON.stringify II", - "topics": [] + "topics": [ + "recursion" + ] }, "skeleton": { "js": "/**\n * @param {*} value\n * @return {string}\n */\nexport default function jsonStringify(value) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/json-stringify/en-US.json b/apps/web/src/__generated__/questions/javascript/json-stringify/en-US.json index 502751711..60d0f1b23 100644 --- a/apps/web/src/__generated__/questions/javascript/json-stringify/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/json-stringify/en-US.json @@ -39,7 +39,9 @@ "slug": "json-stringify", "subtitle": null, "title": "JSON.stringify", - "topics": [] + "topics": [ + "recursion" + ] }, "skeleton": { "js": "/**\n * @param {*} value\n * @return {string}\n */\nexport default function jsonStringify(value) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/list.en-US.json b/apps/web/src/__generated__/questions/javascript/list.en-US.json index d43c6e346..aa51b1e3d 100644 --- a/apps/web/src/__generated__/questions/javascript/list.en-US.json +++ b/apps/web/src/__generated__/questions/javascript/list.en-US.json @@ -232,9 +232,7 @@ "js", "ts" ], - "nextQuestions": [ - "" - ], + "nextQuestions": [], "published": true, "ranking": 100, "similarQuestions": [ @@ -244,7 +242,9 @@ "slug": "backbone-model", "subtitle": null, "title": "Backbone Model", - "topics": [] + "topics": [ + "oop" + ] }, { "access": "premium", @@ -274,7 +274,9 @@ "slug": "camel-case-keys", "subtitle": null, "title": "Camel Case Keys", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -303,7 +305,9 @@ "slug": "cancellable-interval", "subtitle": null, "title": "Cancellable Interval", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -332,7 +336,9 @@ "slug": "cancellable-timeout", "subtitle": null, "title": "Cancellable Timeout", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -718,7 +724,9 @@ "slug": "cycle", "subtitle": null, "title": "Cycle", - "topics": [] + "topics": [ + "closure" + ] }, { "access": "premium", @@ -820,7 +828,9 @@ "slug": "debounce", "subtitle": null, "title": "Debounce", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -858,7 +868,9 @@ "slug": "debounce-ii", "subtitle": null, "title": "Debounce II", - "topics": [] + "topics": [ + "async" + ] }, { "access": "free", @@ -894,7 +906,9 @@ "slug": "deep-clone", "subtitle": null, "title": "Deep Clone", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -923,7 +937,9 @@ "slug": "deep-clone-ii", "subtitle": null, "title": "Deep Clone II", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -955,7 +971,9 @@ "slug": "deep-equal", "subtitle": null, "title": "Deep Equal", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -985,7 +1003,9 @@ "slug": "deep-map", "subtitle": null, "title": "Deep Map", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -1014,7 +1034,9 @@ "slug": "deep-merge", "subtitle": null, "title": "Deep Merge", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -1043,7 +1065,9 @@ "slug": "deep-omit", "subtitle": null, "title": "Deep Omit", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -1169,7 +1193,9 @@ "slug": "event-emitter", "subtitle": null, "title": "Event Emitter", - "topics": [] + "topics": [ + "oop" + ] }, { "access": "premium", @@ -1205,7 +1231,9 @@ "slug": "event-emitter-ii", "subtitle": null, "title": "Event Emitter II", - "topics": [] + "topics": [ + "oop" + ] }, { "access": "premium", @@ -1331,7 +1359,9 @@ "slug": "flatten", "subtitle": null, "title": "Flatten", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -1515,7 +1545,9 @@ "slug": "get", "subtitle": null, "title": "Get", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -1551,7 +1583,9 @@ "slug": "get-elements-by-class-name", "subtitle": null, "title": "getElementsByClassName", - "topics": [] + "topics": [ + "web-api" + ] }, { "access": "premium", @@ -1585,7 +1619,9 @@ "slug": "get-elements-by-style", "subtitle": null, "title": "getElementsByStyle", - "topics": [] + "topics": [ + "web-api" + ] }, { "access": "premium", @@ -1618,7 +1654,9 @@ "slug": "get-elements-by-tag-name", "subtitle": null, "title": "getElementsByTagName", - "topics": [] + "topics": [ + "web-api" + ] }, { "access": "premium", @@ -1652,7 +1690,9 @@ "slug": "get-elements-by-tag-name-hierarchy", "subtitle": null, "title": "getElementsByTagNameHierarchy", - "topics": [] + "topics": [ + "web-api" + ] }, { "access": "premium", @@ -1713,7 +1753,9 @@ "slug": "html-serializer", "subtitle": null, "title": "HTML Serializer", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -1743,7 +1785,11 @@ "slug": "identical-dom-trees", "subtitle": null, "title": "Identical DOM Trees", - "topics": [] + "topics": [ + "recursion", + "tree", + "web-api" + ] }, { "access": "premium", @@ -1920,7 +1966,10 @@ "slug": "jquery-class-manipulation", "subtitle": null, "title": "jQuery Class Manipulation", - "topics": [] + "topics": [ + "oop", + "web-api" + ] }, { "access": "premium", @@ -1951,7 +2000,10 @@ "slug": "jquery-css", "subtitle": null, "title": "jQuery.css", - "topics": [] + "topics": [ + "oop", + "web-api" + ] }, { "access": "premium", @@ -1984,7 +2036,9 @@ "slug": "json-stringify", "subtitle": null, "title": "JSON.stringify", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -2015,7 +2069,9 @@ "slug": "json-stringify-ii", "subtitle": null, "title": "JSON.stringify II", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -2106,7 +2162,9 @@ "slug": "make-counter", "subtitle": null, "title": "Make Counter", - "topics": [] + "topics": [ + "closure" + ] }, { "access": "premium", @@ -2138,7 +2196,9 @@ "slug": "make-counter-ii", "subtitle": null, "title": "Make Counter II", - "topics": [] + "topics": [ + "closure" + ] }, { "access": "premium", @@ -2173,7 +2233,9 @@ "slug": "map-async", "subtitle": null, "title": "Map Async", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -2206,7 +2268,9 @@ "slug": "map-async-limit", "subtitle": null, "title": "Map Async Limit", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -2448,7 +2512,9 @@ "slug": "once", "subtitle": null, "title": "Once", - "topics": [] + "topics": [ + "closure" + ] }, { "access": "free", @@ -2489,7 +2555,9 @@ "slug": "promise-all", "subtitle": null, "title": "Promise.all", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -2520,7 +2588,9 @@ "slug": "promise-all-settled", "subtitle": null, "title": "Promise.allSettled", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -2551,7 +2621,9 @@ "slug": "promise-any", "subtitle": null, "title": "Promise.any", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -2583,7 +2655,9 @@ "slug": "promise-merge", "subtitle": null, "title": "Promise Merge", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -2616,7 +2690,9 @@ "slug": "promise-race", "subtitle": null, "title": "Promise.race", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -2649,7 +2725,9 @@ "slug": "promise-reject", "subtitle": null, "title": "Promise.reject", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -2682,7 +2760,9 @@ "slug": "promise-resolve", "subtitle": null, "title": "Promise.resolve", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -2709,7 +2789,9 @@ "slug": "promise-timeout", "subtitle": null, "title": "Promise Timeout", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -2739,7 +2821,9 @@ "slug": "promise-with-resolvers", "subtitle": null, "title": "Promise.withResolvers", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -2770,7 +2854,9 @@ "slug": "promisify", "subtitle": null, "title": "Promisify", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -2797,7 +2883,9 @@ "slug": "promisify-ii", "subtitle": null, "title": "Promisify II", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -2890,7 +2978,10 @@ "slug": "resumable-interval", "subtitle": null, "title": "Resumable Interval", - "topics": [] + "topics": [ + "async", + "closure" + ] }, { "access": "premium", @@ -2971,7 +3062,9 @@ "slug": "sleep", "subtitle": null, "title": "Sleep", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -3001,7 +3094,9 @@ "slug": "squash-object", "subtitle": null, "title": "Squash Object", - "topics": [] + "topics": [ + "recursion" + ] }, { "access": "premium", @@ -3033,7 +3128,9 @@ "slug": "sum", "subtitle": null, "title": "Sum", - "topics": [] + "topics": [ + "closure" + ] }, { "access": "premium", @@ -3063,7 +3160,11 @@ "slug": "table-of-contents", "subtitle": null, "title": "Table of Contents", - "topics": [] + "topics": [ + "recursion", + "tree", + "web-api" + ] }, { "access": "premium", @@ -3161,7 +3262,9 @@ "slug": "throttle", "subtitle": null, "title": "Throttle", - "topics": [] + "topics": [ + "async" + ] }, { "access": "premium", @@ -3188,7 +3291,9 @@ "slug": "turtle", "subtitle": null, "title": "Turtle", - "topics": [] + "topics": [ + "oop" + ] }, { "access": "free", diff --git a/apps/web/src/__generated__/questions/javascript/make-counter-ii/en-US.json b/apps/web/src/__generated__/questions/javascript/make-counter-ii/en-US.json index e3962d78a..9bbce7a4f 100644 --- a/apps/web/src/__generated__/questions/javascript/make-counter-ii/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/make-counter-ii/en-US.json @@ -38,7 +38,9 @@ "slug": "make-counter-ii", "subtitle": null, "title": "Make Counter II", - "topics": [] + "topics": [ + "closure" + ] }, "skeleton": { "js": "/**\n * @param {number} initialValue\n * @return {{get: Function, increment: Function, decrement: Function, reset: Function }}\n */\nexport default function makeCounter(initialValue = 0) {\n throw 'Not implemented';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/make-counter/en-US.json b/apps/web/src/__generated__/questions/javascript/make-counter/en-US.json index 298e8d07c..929330c3a 100644 --- a/apps/web/src/__generated__/questions/javascript/make-counter/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/make-counter/en-US.json @@ -39,7 +39,9 @@ "slug": "make-counter", "subtitle": null, "title": "Make Counter", - "topics": [] + "topics": [ + "closure" + ] }, "skeleton": { "js": "/**\n * @param {number} initialValue\n * @return {Function}\n */\nexport default function makeCounter(initialValue = 0) {\n throw 'Not implemented';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/map-async-limit/en-US.json b/apps/web/src/__generated__/questions/javascript/map-async-limit/en-US.json index e2a94e62f..9244bbc60 100644 --- a/apps/web/src/__generated__/questions/javascript/map-async-limit/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/map-async-limit/en-US.json @@ -39,7 +39,9 @@ "slug": "map-async-limit", "subtitle": null, "title": "Map Async Limit", - "topics": [] + "topics": [ + "async" + ] }, "skeleton": { "js": "/**\n * @param {Array} iterable\n * @param {Function} callbackFn\n * @param {number} size\n *\n * @return {Promise}\n */\nexport default function mapAsyncLimit(iterable, callbackFn, size) {\n throw 'Not implemented';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/map-async/en-US.json b/apps/web/src/__generated__/questions/javascript/map-async/en-US.json index b2ec02e4f..93ea105d3 100644 --- a/apps/web/src/__generated__/questions/javascript/map-async/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/map-async/en-US.json @@ -41,7 +41,9 @@ "slug": "map-async", "subtitle": null, "title": "Map Async", - "topics": [] + "topics": [ + "async" + ] }, "skeleton": { "js": "/**\n * @param {Array} iterable\n * @param {Function} callbackFn\n *\n * @return {Promise}\n */\nexport default function mapAsync(iterable, callbackFn) {\n throw 'Not implemented';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/once/en-US.json b/apps/web/src/__generated__/questions/javascript/once/en-US.json index 4b2ee9dc6..ec4f76373 100644 --- a/apps/web/src/__generated__/questions/javascript/once/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/once/en-US.json @@ -37,7 +37,9 @@ "slug": "once", "subtitle": null, "title": "Once", - "topics": [] + "topics": [ + "closure" + ] }, "skeleton": { "js": "/**\n * @template {Function} T\n * @param {T} func\n * @return {T}\n */\nexport default function once(func) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/promise-all-settled/en-US.json b/apps/web/src/__generated__/questions/javascript/promise-all-settled/en-US.json index 0688f60ba..6f6209303 100644 --- a/apps/web/src/__generated__/questions/javascript/promise-all-settled/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/promise-all-settled/en-US.json @@ -37,7 +37,9 @@ "slug": "promise-all-settled", "subtitle": null, "title": "Promise.allSettled", - "topics": [] + "topics": [ + "async" + ] }, "skeleton": { "js": "/**\n * @param {Array} iterable\n * @return {Promise>}\n */\nexport default function promiseAllSettled(iterable) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/promise-all/en-US.json b/apps/web/src/__generated__/questions/javascript/promise-all/en-US.json index 51c30cd90..58b329401 100644 --- a/apps/web/src/__generated__/questions/javascript/promise-all/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/promise-all/en-US.json @@ -47,7 +47,9 @@ "slug": "promise-all", "subtitle": null, "title": "Promise.all", - "topics": [] + "topics": [ + "async" + ] }, "skeleton": { "js": "/**\n * @param {Array} iterable\n * @return {Promise}\n */\nexport default function promiseAll(iterable) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/promise-any/en-US.json b/apps/web/src/__generated__/questions/javascript/promise-any/en-US.json index 67ebc3cbd..fbff4e6c1 100644 --- a/apps/web/src/__generated__/questions/javascript/promise-any/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/promise-any/en-US.json @@ -37,7 +37,9 @@ "slug": "promise-any", "subtitle": null, "title": "Promise.any", - "topics": [] + "topics": [ + "async" + ] }, "skeleton": { "js": "/**\n * @param {Array} iterable\n * @return {Promise}\n */\nexport default function promiseAny(iterable) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/promise-merge/en-US.json b/apps/web/src/__generated__/questions/javascript/promise-merge/en-US.json index 99f14efea..b6bb6a2ee 100644 --- a/apps/web/src/__generated__/questions/javascript/promise-merge/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/promise-merge/en-US.json @@ -38,7 +38,9 @@ "slug": "promise-merge", "subtitle": null, "title": "Promise Merge", - "topics": [] + "topics": [ + "async" + ] }, "skeleton": { "js": "/**\n * @param {Promise} p1\n * @param {Promise} p2\n * @return {Promise}\n */\nexport default function promiseMerge(p1, p2) {\n throw 'Not implemented';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/promise-race/en-US.json b/apps/web/src/__generated__/questions/javascript/promise-race/en-US.json index 0a6ca232a..b8a3bc82a 100644 --- a/apps/web/src/__generated__/questions/javascript/promise-race/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/promise-race/en-US.json @@ -39,7 +39,9 @@ "slug": "promise-race", "subtitle": null, "title": "Promise.race", - "topics": [] + "topics": [ + "async" + ] }, "skeleton": { "js": "/**\n * @param {Array} iterable\n * @return {Promise}\n */\nexport default function promiseRace(iterable) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/promise-reject/en-US.json b/apps/web/src/__generated__/questions/javascript/promise-reject/en-US.json index 5136b2b41..456067ad8 100644 --- a/apps/web/src/__generated__/questions/javascript/promise-reject/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/promise-reject/en-US.json @@ -39,7 +39,9 @@ "slug": "promise-reject", "subtitle": null, "title": "Promise.reject", - "topics": [] + "topics": [ + "async" + ] }, "skeleton": { "js": "/**\n * @param {*} reason\n * @returns Promise\n */\nexport default function promiseReject(reason) {\n throw 'Not implemented';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/promise-resolve/en-US.json b/apps/web/src/__generated__/questions/javascript/promise-resolve/en-US.json index ddf0f05f4..37b62a115 100644 --- a/apps/web/src/__generated__/questions/javascript/promise-resolve/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/promise-resolve/en-US.json @@ -39,7 +39,9 @@ "slug": "promise-resolve", "subtitle": null, "title": "Promise.resolve", - "topics": [] + "topics": [ + "async" + ] }, "skeleton": { "js": "/**\n * @param {*} value\n * @returns Promise\n */\nexport default function promiseResolve(value) {\n throw 'Not implemented';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/promise-timeout/en-US.json b/apps/web/src/__generated__/questions/javascript/promise-timeout/en-US.json index 3f8cd6a34..5281096f3 100644 --- a/apps/web/src/__generated__/questions/javascript/promise-timeout/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/promise-timeout/en-US.json @@ -33,7 +33,9 @@ "slug": "promise-timeout", "subtitle": null, "title": "Promise Timeout", - "topics": [] + "topics": [ + "async" + ] }, "skeleton": { "js": "/**\n * @template T\n * @param {Promise} promise\n * @param {number} duration\n * @return {Promise}\n */\nexport default function promiseTimeout(promise, duration) {\n throw 'Not implemented';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/promise-with-resolvers/en-US.json b/apps/web/src/__generated__/questions/javascript/promise-with-resolvers/en-US.json index 515609322..91a3310d5 100644 --- a/apps/web/src/__generated__/questions/javascript/promise-with-resolvers/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/promise-with-resolvers/en-US.json @@ -36,7 +36,9 @@ "slug": "promise-with-resolvers", "subtitle": null, "title": "Promise.withResolvers", - "topics": [] + "topics": [ + "async" + ] }, "skeleton": { "js": "/**\n * @returns { promise: Promise, resolve: Function, reject: Function }\n */\nexport default function promiseWithResolvers() {\n throw 'Not implemented';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/promisify-ii/en-US.json b/apps/web/src/__generated__/questions/javascript/promisify-ii/en-US.json index ae6fbebc5..2ec586bde 100644 --- a/apps/web/src/__generated__/questions/javascript/promisify-ii/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/promisify-ii/en-US.json @@ -33,7 +33,9 @@ "slug": "promisify-ii", "subtitle": null, "title": "Promisify II", - "topics": [] + "topics": [ + "async" + ] }, "skeleton": { "js": "/**\n * @callback func\n * @returns Function\n */\nexport default function promisify(func) {\n throw 'Not implemented';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/promisify/en-US.json b/apps/web/src/__generated__/questions/javascript/promisify/en-US.json index 96d42bc2f..4415f8751 100644 --- a/apps/web/src/__generated__/questions/javascript/promisify/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/promisify/en-US.json @@ -37,7 +37,9 @@ "slug": "promisify", "subtitle": null, "title": "Promisify", - "topics": [] + "topics": [ + "async" + ] }, "skeleton": { "js": "/**\n * @callback func\n * @returns Function\n */\nexport default function promisify(func) {\n throw 'Not implemented';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/resumable-interval/en-US.json b/apps/web/src/__generated__/questions/javascript/resumable-interval/en-US.json index 77bccaf5b..f772469d3 100644 --- a/apps/web/src/__generated__/questions/javascript/resumable-interval/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/resumable-interval/en-US.json @@ -35,7 +35,10 @@ "slug": "resumable-interval", "subtitle": null, "title": "Resumable Interval", - "topics": [] + "topics": [ + "async", + "closure" + ] }, "skeleton": { "js": "/**\n * @param {Function} callback\n * @param {number} delay\n * @param {...any} args\n * @returns {{start: Function, pause: Function, stop: Function}}\n */\nexport default function createResumableInterval(callback, delay, ...args) {\n throw 'Not implemented';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/sleep/en-US.json b/apps/web/src/__generated__/questions/javascript/sleep/en-US.json index aa28837c6..ad4ccb7ef 100644 --- a/apps/web/src/__generated__/questions/javascript/sleep/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/sleep/en-US.json @@ -33,7 +33,9 @@ "slug": "sleep", "subtitle": null, "title": "Sleep", - "topics": [] + "topics": [ + "async" + ] }, "skeleton": { "js": "/**\n * @param {number} duration\n * @return {Promise}\n */\nexport default async function sleep(duration) {\n throw 'Not implemented';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/squash-object/en-US.json b/apps/web/src/__generated__/questions/javascript/squash-object/en-US.json index 9c0255d05..160fa11ca 100644 --- a/apps/web/src/__generated__/questions/javascript/squash-object/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/squash-object/en-US.json @@ -36,7 +36,9 @@ "slug": "squash-object", "subtitle": null, "title": "Squash Object", - "topics": [] + "topics": [ + "recursion" + ] }, "skeleton": { "js": "/**\n * @param {Object} obj\n * @return {Object}\n */\nexport default function squashObject(obj) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/sum/en-US.json b/apps/web/src/__generated__/questions/javascript/sum/en-US.json index e8c9381e2..7a2f51dd8 100644 --- a/apps/web/src/__generated__/questions/javascript/sum/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/sum/en-US.json @@ -38,7 +38,9 @@ "slug": "sum", "subtitle": null, "title": "Sum", - "topics": [] + "topics": [ + "closure" + ] }, "skeleton": { "js": "/**\n * @param {number} value\n * @return {Function}\n */\nexport default function sum(value) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/table-of-contents/en-US.json b/apps/web/src/__generated__/questions/javascript/table-of-contents/en-US.json index 41f15fc58..c91214f36 100644 --- a/apps/web/src/__generated__/questions/javascript/table-of-contents/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/table-of-contents/en-US.json @@ -36,7 +36,11 @@ "slug": "table-of-contents", "subtitle": null, "title": "Table of Contents", - "topics": [] + "topics": [ + "recursion", + "tree", + "web-api" + ] }, "skeleton": { "js": "/**\n * @param {Document} doc\n * @return {string}\n */\nexport default function tableOfContents(doc) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/throttle/en-US.json b/apps/web/src/__generated__/questions/javascript/throttle/en-US.json index bb34e76e8..67562b903 100644 --- a/apps/web/src/__generated__/questions/javascript/throttle/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/throttle/en-US.json @@ -40,7 +40,9 @@ "slug": "throttle", "subtitle": null, "title": "Throttle", - "topics": [] + "topics": [ + "async" + ] }, "skeleton": { "js": "/**\n * @callback func\n * @param {number} wait\n * @return {Function}\n */\nexport default function throttle(func, wait) {\n throw 'Not implemented!';\n}", diff --git a/apps/web/src/__generated__/questions/javascript/turtle/en-US.json b/apps/web/src/__generated__/questions/javascript/turtle/en-US.json index 666b766dc..560ccf0a5 100644 --- a/apps/web/src/__generated__/questions/javascript/turtle/en-US.json +++ b/apps/web/src/__generated__/questions/javascript/turtle/en-US.json @@ -33,7 +33,9 @@ "slug": "turtle", "subtitle": null, "title": "Turtle", - "topics": [] + "topics": [ + "oop" + ] }, "skeleton": { "js": "export default class Turtle {\n constructor() {\n throw 'Not implemented';\n }\n\n /**\n * @param {number} distance Distance to move forward while facing the current direction.\n * @return {Turtle}\n */\n forward(distance) {\n throw 'Not implemented';\n }\n\n /**\n * @param {number} distance Distance to move backward while facing the current direction.\n * @return {Turtle}\n */\n backward(distance) {\n throw 'Not implemented';\n }\n\n /**\n * Turns the turtle left.\n * @return {Turtle}\n */\n left() {\n throw 'Not implemented';\n }\n\n /**\n * Turns the turtle right.\n * @return {Turtle}\n */\n right() {\n throw 'Not implemented';\n }\n\n /**\n * @return {[number, number]} Coordinates [x, y]\n */\n position() {\n throw 'Not implemented';\n }\n}", diff --git a/apps/web/src/__generated__/questions/quiz/describe-event-bubbling/en-US.json b/apps/web/src/__generated__/questions/quiz/describe-event-bubbling/en-US.json index e7706ea14..3dfc73de2 100644 --- a/apps/web/src/__generated__/questions/quiz/describe-event-bubbling/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/describe-event-bubbling/en-US.json @@ -24,8 +24,8 @@ "subtitle": null, "title": "Describe event bubbling in JavaScript and browsers", "topics": [ - "javascript", - "html" + "web-api", + "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/describe-event-bubbling/en-US.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/describe-event-bubbling/pt-BR.json b/apps/web/src/__generated__/questions/quiz/describe-event-bubbling/pt-BR.json index 0bb3e20f4..fdb4a2d35 100644 --- a/apps/web/src/__generated__/questions/quiz/describe-event-bubbling/pt-BR.json +++ b/apps/web/src/__generated__/questions/quiz/describe-event-bubbling/pt-BR.json @@ -24,8 +24,8 @@ "subtitle": null, "title": "Descreva a propagação de eventos", "topics": [ - "javascript", - "html" + "web-api", + "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/describe-event-bubbling/pt-BR.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/describe-event-bubbling/zh-CN.json b/apps/web/src/__generated__/questions/quiz/describe-event-bubbling/zh-CN.json index 5130e3ce9..a0a5cba4c 100644 --- a/apps/web/src/__generated__/questions/quiz/describe-event-bubbling/zh-CN.json +++ b/apps/web/src/__generated__/questions/quiz/describe-event-bubbling/zh-CN.json @@ -24,8 +24,8 @@ "subtitle": null, "title": "描述事件冒泡过程", "topics": [ - "javascript", - "html" + "web-api", + "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/describe-event-bubbling/zh-CN.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/describe-event-capturing/en-US.json b/apps/web/src/__generated__/questions/quiz/describe-event-capturing/en-US.json index aac115a9d..32393c06a 100644 --- a/apps/web/src/__generated__/questions/quiz/describe-event-capturing/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/describe-event-capturing/en-US.json @@ -24,8 +24,8 @@ "subtitle": null, "title": "Describe event capturing in JavaScript and browsers", "topics": [ - "javascript", - "html" + "web-api", + "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/describe-event-capturing/en-US.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/describe-the-difference-between-a-cookie-sessionstorage-and-localstorage/en-US.json b/apps/web/src/__generated__/questions/quiz/describe-the-difference-between-a-cookie-sessionstorage-and-localstorage/en-US.json index 06e9bdff0..7962825ad 100644 --- a/apps/web/src/__generated__/questions/quiz/describe-the-difference-between-a-cookie-sessionstorage-and-localstorage/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/describe-the-difference-between-a-cookie-sessionstorage-and-localstorage/en-US.json @@ -27,6 +27,7 @@ "subtitle": null, "title": "Describe the difference between a cookie, `sessionStorage` and `localStorage` in browsers", "topics": [ + "web-api", "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/describe-the-difference-between-a-cookie-sessionstorage-and-localstorage/en-US.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/describe-the-difference-between-a-cookie-sessionstorage-and-localstorage/pt-BR.json b/apps/web/src/__generated__/questions/quiz/describe-the-difference-between-a-cookie-sessionstorage-and-localstorage/pt-BR.json index 08b42e887..168c3c25a 100644 --- a/apps/web/src/__generated__/questions/quiz/describe-the-difference-between-a-cookie-sessionstorage-and-localstorage/pt-BR.json +++ b/apps/web/src/__generated__/questions/quiz/describe-the-difference-between-a-cookie-sessionstorage-and-localstorage/pt-BR.json @@ -27,6 +27,7 @@ "subtitle": null, "title": "Descreva a diferença entre cookie, `sessionStorage` e `localStorage`.", "topics": [ + "web-api", "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/describe-the-difference-between-a-cookie-sessionstorage-and-localstorage/pt-BR.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/describe-the-difference-between-a-cookie-sessionstorage-and-localstorage/zh-CN.json b/apps/web/src/__generated__/questions/quiz/describe-the-difference-between-a-cookie-sessionstorage-and-localstorage/zh-CN.json index 2a1338b98..5581c4331 100644 --- a/apps/web/src/__generated__/questions/quiz/describe-the-difference-between-a-cookie-sessionstorage-and-localstorage/zh-CN.json +++ b/apps/web/src/__generated__/questions/quiz/describe-the-difference-between-a-cookie-sessionstorage-and-localstorage/zh-CN.json @@ -27,6 +27,7 @@ "subtitle": null, "title": "描述cookie、 `sessionStorage` 和 `localStorage` 之间的差异。", "topics": [ + "web-api", "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/describe-the-difference-between-a-cookie-sessionstorage-and-localstorage/zh-CN.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/difference-between-document-load-event-and-document-domcontentloaded-event/en-US.json b/apps/web/src/__generated__/questions/quiz/difference-between-document-load-event-and-document-domcontentloaded-event/en-US.json index 8346b1448..7881df847 100644 --- a/apps/web/src/__generated__/questions/quiz/difference-between-document-load-event-and-document-domcontentloaded-event/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/difference-between-document-load-event-and-document-domcontentloaded-event/en-US.json @@ -24,8 +24,8 @@ "subtitle": null, "title": "Difference between document `load` event and document `DOMContentLoaded` event?", "topics": [ - "javascript", - "html" + "html", + "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/difference-between-document-load-event-and-document-domcontentloaded-event/en-US.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/difference-between-document-load-event-and-document-domcontentloaded-event/pt-BR.json b/apps/web/src/__generated__/questions/quiz/difference-between-document-load-event-and-document-domcontentloaded-event/pt-BR.json index e45d2db19..a7f4c06bb 100644 --- a/apps/web/src/__generated__/questions/quiz/difference-between-document-load-event-and-document-domcontentloaded-event/pt-BR.json +++ b/apps/web/src/__generated__/questions/quiz/difference-between-document-load-event-and-document-domcontentloaded-event/pt-BR.json @@ -24,8 +24,8 @@ "subtitle": null, "title": "Qual a diferença entre o evento `load` do documento e o evento `DOMContentLoaded` do documento?", "topics": [ - "javascript", - "html" + "html", + "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/difference-between-document-load-event-and-document-domcontentloaded-event/pt-BR.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/difference-between-document-load-event-and-document-domcontentloaded-event/zh-CN.json b/apps/web/src/__generated__/questions/quiz/difference-between-document-load-event-and-document-domcontentloaded-event/zh-CN.json index 3a028320b..f3af0866b 100644 --- a/apps/web/src/__generated__/questions/quiz/difference-between-document-load-event-and-document-domcontentloaded-event/zh-CN.json +++ b/apps/web/src/__generated__/questions/quiz/difference-between-document-load-event-and-document-domcontentloaded-event/zh-CN.json @@ -24,8 +24,8 @@ "subtitle": null, "title": "Document `load` 事件和 `DOMContentLoaded` 事件之间的区别?", "topics": [ - "javascript", - "html" + "html", + "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/difference-between-document-load-event-and-document-domcontentloaded-event/zh-CN.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/difference-between-function-person-var-person-person-and-var-person-new-person/en-US.json b/apps/web/src/__generated__/questions/quiz/difference-between-function-person-var-person-person-and-var-person-new-person/en-US.json index 5ee6f9fd9..80202136c 100644 --- a/apps/web/src/__generated__/questions/quiz/difference-between-function-person-var-person-person-and-var-person-new-person/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/difference-between-function-person-var-person-person-and-var-person-new-person/en-US.json @@ -24,7 +24,8 @@ "subtitle": null, "title": "Difference between: `function Person(){}`, `const person = Person()`, and `const person = new Person()` in JavaScript?", "topics": [ - "javascript" + "javascript", + "oop" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/difference-between-function-person-var-person-person-and-var-person-new-person/en-US.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/difference-between-function-person-var-person-person-and-var-person-new-person/pt-BR.json b/apps/web/src/__generated__/questions/quiz/difference-between-function-person-var-person-person-and-var-person-new-person/pt-BR.json index e0fce5a4f..9576ab878 100644 --- a/apps/web/src/__generated__/questions/quiz/difference-between-function-person-var-person-person-and-var-person-new-person/pt-BR.json +++ b/apps/web/src/__generated__/questions/quiz/difference-between-function-person-var-person-person-and-var-person-new-person/pt-BR.json @@ -24,7 +24,8 @@ "subtitle": null, "title": "Diferença entre: `function Person(){}`, `var person = Person()`, e `var person = new Person()`?", "topics": [ - "javascript" + "javascript", + "oop" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/difference-between-function-person-var-person-person-and-var-person-new-person/pt-BR.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/difference-between-function-person-var-person-person-and-var-person-new-person/zh-CN.json b/apps/web/src/__generated__/questions/quiz/difference-between-function-person-var-person-person-and-var-person-new-person/zh-CN.json index 57c3c89fa..b43324411 100644 --- a/apps/web/src/__generated__/questions/quiz/difference-between-function-person-var-person-person-and-var-person-new-person/zh-CN.json +++ b/apps/web/src/__generated__/questions/quiz/difference-between-function-person-var-person-person-and-var-person-new-person/zh-CN.json @@ -24,7 +24,8 @@ "subtitle": null, "title": "比较差异: `function Person(){}`, `var person = Person()`, 和 `var person = new Person()`?", "topics": [ - "javascript" + "javascript", + "oop" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/difference-between-function-person-var-person-person-and-var-person-new-person/zh-CN.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/explain-ajax-in-as-much-detail-as-possible/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-ajax-in-as-much-detail-as-possible/en-US.json index 9599433bd..0c6c7a398 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-ajax-in-as-much-detail-as-possible/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-ajax-in-as-much-detail-as-possible/en-US.json @@ -25,7 +25,7 @@ "title": "Explain AJAX in as much detail as possible", "topics": [ "javascript", - "network" + "networking" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-ajax-in-as-much-detail-as-possible/en-US.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/explain-ajax-in-as-much-detail-as-possible/pt-BR.json b/apps/web/src/__generated__/questions/quiz/explain-ajax-in-as-much-detail-as-possible/pt-BR.json index bf16c33ce..19445675e 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-ajax-in-as-much-detail-as-possible/pt-BR.json +++ b/apps/web/src/__generated__/questions/quiz/explain-ajax-in-as-much-detail-as-possible/pt-BR.json @@ -25,7 +25,7 @@ "title": "Explique o Ajax com o máximo de detalhes possível.", "topics": [ "javascript", - "network" + "networking" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-ajax-in-as-much-detail-as-possible/pt-BR.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/explain-ajax-in-as-much-detail-as-possible/zh-CN.json b/apps/web/src/__generated__/questions/quiz/explain-ajax-in-as-much-detail-as-possible/zh-CN.json index 9dcdd2c16..e606f40cf 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-ajax-in-as-much-detail-as-possible/zh-CN.json +++ b/apps/web/src/__generated__/questions/quiz/explain-ajax-in-as-much-detail-as-possible/zh-CN.json @@ -25,7 +25,7 @@ "title": "尽可能详细地解释Ajax", "topics": [ "javascript", - "network" + "networking" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-ajax-in-as-much-detail-as-possible/zh-CN.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/explain-event-delegation/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-event-delegation/en-US.json index 335042ec6..eaf75e91e 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-event-delegation/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-event-delegation/en-US.json @@ -26,8 +26,8 @@ "subtitle": null, "title": "Explain event delegation in JavaScript", "topics": [ - "javascript", - "html" + "web-api", + "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-event-delegation/en-US.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/explain-event-delegation/pt-BR.json b/apps/web/src/__generated__/questions/quiz/explain-event-delegation/pt-BR.json index 94aa917f4..5fb74302d 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-event-delegation/pt-BR.json +++ b/apps/web/src/__generated__/questions/quiz/explain-event-delegation/pt-BR.json @@ -26,8 +26,8 @@ "subtitle": null, "title": "Explique delegação do evento", "topics": [ - "javascript", - "html" + "web-api", + "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-event-delegation/pt-BR.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/explain-event-delegation/zh-CN.json b/apps/web/src/__generated__/questions/quiz/explain-event-delegation/zh-CN.json index 344ca50d1..ef53ea010 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-event-delegation/zh-CN.json +++ b/apps/web/src/__generated__/questions/quiz/explain-event-delegation/zh-CN.json @@ -26,8 +26,8 @@ "subtitle": null, "title": "解释事件委托", "topics": [ - "javascript", - "html" + "web-api", + "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-event-delegation/zh-CN.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/explain-function-prototype-bind/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-function-prototype-bind/en-US.json index 77f8aeba7..a11bffcaa 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-function-prototype-bind/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-function-prototype-bind/en-US.json @@ -24,7 +24,8 @@ "subtitle": null, "title": "Explain `Function.prototype.bind` in JavaScript", "topics": [ - "javascript" + "javascript", + "oop" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-function-prototype-bind/en-US.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/explain-function-prototype-bind/pt-BR.json b/apps/web/src/__generated__/questions/quiz/explain-function-prototype-bind/pt-BR.json index fbc1d1909..dd5f2c9a0 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-function-prototype-bind/pt-BR.json +++ b/apps/web/src/__generated__/questions/quiz/explain-function-prototype-bind/pt-BR.json @@ -24,7 +24,8 @@ "subtitle": null, "title": "Explique `Function.prototype.bind`", "topics": [ - "javascript" + "javascript", + "oop" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-function-prototype-bind/pt-BR.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/explain-function-prototype-bind/zh-CN.json b/apps/web/src/__generated__/questions/quiz/explain-function-prototype-bind/zh-CN.json index 51f58a132..27d0d6f1b 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-function-prototype-bind/zh-CN.json +++ b/apps/web/src/__generated__/questions/quiz/explain-function-prototype-bind/zh-CN.json @@ -24,7 +24,8 @@ "subtitle": null, "title": "解释 `Function.prototype.bind`", "topics": [ - "javascript" + "javascript", + "oop" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-function-prototype-bind/zh-CN.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/explain-how-a-browser-determines-what-elements-match-a-css-selector/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-how-a-browser-determines-what-elements-match-a-css-selector/en-US.json index 3fdcedf78..bbedda582 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-how-a-browser-determines-what-elements-match-a-css-selector/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-how-a-browser-determines-what-elements-match-a-css-selector/en-US.json @@ -24,6 +24,7 @@ "subtitle": null, "title": "Explain how a browser determines what elements match a CSS selector.", "topics": [ + "browser", "css" ], "gitHubEditUrl": "https://github.com/yangshun/front-end-interview-handbook/blob/main/packages/quiz/questions/explain-how-a-browser-determines-what-elements-match-a-css-selector/en-US.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/explain-how-a-browser-determines-what-elements-match-a-css-selector/pt-BR.json b/apps/web/src/__generated__/questions/quiz/explain-how-a-browser-determines-what-elements-match-a-css-selector/pt-BR.json index 88b6800d9..59726f993 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-how-a-browser-determines-what-elements-match-a-css-selector/pt-BR.json +++ b/apps/web/src/__generated__/questions/quiz/explain-how-a-browser-determines-what-elements-match-a-css-selector/pt-BR.json @@ -24,6 +24,7 @@ "subtitle": null, "title": "Explique como um navegador determina quais elementos correspondem a um seletor CSS.", "topics": [ + "browser", "css" ], "gitHubEditUrl": "https://github.com/yangshun/front-end-interview-handbook/blob/main/packages/quiz/questions/explain-how-a-browser-determines-what-elements-match-a-css-selector/pt-BR.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/explain-how-a-browser-determines-what-elements-match-a-css-selector/zh-CN.json b/apps/web/src/__generated__/questions/quiz/explain-how-a-browser-determines-what-elements-match-a-css-selector/zh-CN.json index 471452305..4dde2a99c 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-how-a-browser-determines-what-elements-match-a-css-selector/zh-CN.json +++ b/apps/web/src/__generated__/questions/quiz/explain-how-a-browser-determines-what-elements-match-a-css-selector/zh-CN.json @@ -24,6 +24,7 @@ "subtitle": null, "title": "解释浏览器如何决定什么元素与 CSS 选择器匹配。", "topics": [ + "browser", "css" ], "gitHubEditUrl": "https://github.com/yangshun/front-end-interview-handbook/blob/main/packages/quiz/questions/explain-how-a-browser-determines-what-elements-match-a-css-selector/zh-CN.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/explain-how-jsonp-works-and-how-its-not-really-ajax/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-how-jsonp-works-and-how-its-not-really-ajax/en-US.json index d3848e655..08010678c 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-how-jsonp-works-and-how-its-not-really-ajax/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-how-jsonp-works-and-how-its-not-really-ajax/en-US.json @@ -25,7 +25,7 @@ "title": "Explain how JSONP works (and how it's not really Ajax)", "topics": [ "javascript", - "network", + "networking", "security" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-how-jsonp-works-and-how-its-not-really-ajax/en-US.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/explain-how-jsonp-works-and-how-its-not-really-ajax/pt-BR.json b/apps/web/src/__generated__/questions/quiz/explain-how-jsonp-works-and-how-its-not-really-ajax/pt-BR.json index 713f94f25..0d7202208 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-how-jsonp-works-and-how-its-not-really-ajax/pt-BR.json +++ b/apps/web/src/__generated__/questions/quiz/explain-how-jsonp-works-and-how-its-not-really-ajax/pt-BR.json @@ -25,7 +25,7 @@ "title": "Explique como o JSONP funciona (e como ele não é Ajax)", "topics": [ "javascript", - "network", + "networking", "security" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-how-jsonp-works-and-how-its-not-really-ajax/pt-BR.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/explain-how-jsonp-works-and-how-its-not-really-ajax/zh-CN.json b/apps/web/src/__generated__/questions/quiz/explain-how-jsonp-works-and-how-its-not-really-ajax/zh-CN.json index b5e6f52ad..5dab635c3 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-how-jsonp-works-and-how-its-not-really-ajax/zh-CN.json +++ b/apps/web/src/__generated__/questions/quiz/explain-how-jsonp-works-and-how-its-not-really-ajax/zh-CN.json @@ -25,7 +25,7 @@ "title": "解释JSONP 如何工作(以及它为什么不是真正的 Ajax)", "topics": [ "javascript", - "network", + "networking", "security" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-how-jsonp-works-and-how-its-not-really-ajax/zh-CN.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/explain-how-prototypal-inheritance-works/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-how-prototypal-inheritance-works/en-US.json index 1a962405d..1dba51fc9 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-how-prototypal-inheritance-works/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-how-prototypal-inheritance-works/en-US.json @@ -24,7 +24,8 @@ "subtitle": null, "title": "Explain how prototypal inheritance works in JavaScript", "topics": [ - "javascript" + "javascript", + "oop" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-how-prototypal-inheritance-works/en-US.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/explain-how-prototypal-inheritance-works/pt-BR.json b/apps/web/src/__generated__/questions/quiz/explain-how-prototypal-inheritance-works/pt-BR.json index 0805152ba..2274e187c 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-how-prototypal-inheritance-works/pt-BR.json +++ b/apps/web/src/__generated__/questions/quiz/explain-how-prototypal-inheritance-works/pt-BR.json @@ -24,7 +24,8 @@ "subtitle": null, "title": "Explique como funciona a herança de protótipos", "topics": [ - "javascript" + "javascript", + "oop" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-how-prototypal-inheritance-works/pt-BR.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/explain-how-prototypal-inheritance-works/zh-CN.json b/apps/web/src/__generated__/questions/quiz/explain-how-prototypal-inheritance-works/zh-CN.json index 40604a646..4c7cee713 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-how-prototypal-inheritance-works/zh-CN.json +++ b/apps/web/src/__generated__/questions/quiz/explain-how-prototypal-inheritance-works/zh-CN.json @@ -24,7 +24,8 @@ "subtitle": null, "title": "解释原型继承如何工作", "topics": [ - "javascript" + "javascript", + "oop" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-how-prototypal-inheritance-works/zh-CN.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/explain-how-this-works-in-javascript/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-how-this-works-in-javascript/en-US.json index 5221c3dbc..48a47eee6 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-how-this-works-in-javascript/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-how-this-works-in-javascript/en-US.json @@ -24,7 +24,8 @@ "subtitle": null, "title": "Explain how `this` works in JavaScript", "topics": [ - "javascript" + "javascript", + "oop" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-how-this-works-in-javascript/en-US.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/explain-how-this-works-in-javascript/pt-BR.json b/apps/web/src/__generated__/questions/quiz/explain-how-this-works-in-javascript/pt-BR.json index de63d5d45..4845221ac 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-how-this-works-in-javascript/pt-BR.json +++ b/apps/web/src/__generated__/questions/quiz/explain-how-this-works-in-javascript/pt-BR.json @@ -24,7 +24,8 @@ "subtitle": null, "title": "Explique como `this` funciona em JavaScript", "topics": [ - "javascript" + "javascript", + "oop" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-how-this-works-in-javascript/pt-BR.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/explain-how-this-works-in-javascript/zh-CN.json b/apps/web/src/__generated__/questions/quiz/explain-how-this-works-in-javascript/zh-CN.json index 0604815c6..a486a484a 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-how-this-works-in-javascript/zh-CN.json +++ b/apps/web/src/__generated__/questions/quiz/explain-how-this-works-in-javascript/zh-CN.json @@ -24,7 +24,8 @@ "subtitle": null, "title": "解释 JavaScript `this` 如何工作", "topics": [ - "javascript" + "javascript", + "oop" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-how-this-works-in-javascript/zh-CN.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-a-callback-function-in-asynchronous-operations/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-a-callback-function-in-asynchronous-operations/en-US.json index e69058a7b..edf5e79a8 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-a-callback-function-in-asynchronous-operations/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-a-callback-function-in-asynchronous-operations/en-US.json @@ -24,6 +24,7 @@ "subtitle": null, "title": "Explain the concept of a callback function in asynchronous operations", "topics": [ + "async", "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-the-concept-of-a-callback-function-in-asynchronous-operations/en-US.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-a-microtask-queue/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-a-microtask-queue/en-US.json index aea183408..349ea207c 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-a-microtask-queue/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-a-microtask-queue/en-US.json @@ -24,6 +24,7 @@ "subtitle": null, "title": "Explain the concept of a microtask queue", "topics": [ + "async", "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-the-concept-of-a-microtask-queue/en-US.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-cross-site-request-forgery-csrf-and-its-mitigation-techniques/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-cross-site-request-forgery-csrf-and-its-mitigation-techniques/en-US.json index 68cf20e18..a4a777ee1 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-cross-site-request-forgery-csrf-and-its-mitigation-techniques/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-cross-site-request-forgery-csrf-and-its-mitigation-techniques/en-US.json @@ -25,7 +25,7 @@ "title": "Explain the concept of Cross-Site Request Forgery (CSRF) and its mitigation techniques", "topics": [ "javascript", - "network", + "networking", "security" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-the-concept-of-cross-site-request-forgery-csrf-and-its-mitigation-techniques/en-US.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-debouncing-and-throttling/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-debouncing-and-throttling/en-US.json index f63092ae3..30ff277f0 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-debouncing-and-throttling/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-debouncing-and-throttling/en-US.json @@ -24,6 +24,7 @@ "subtitle": null, "title": "Explain the concept of debouncing and throttling", "topics": [ + "async", "javascript", "performance" ], diff --git a/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-inheritance-in-es2015-classes/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-inheritance-in-es2015-classes/en-US.json index de6521da8..f09bd3ff8 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-inheritance-in-es2015-classes/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-inheritance-in-es2015-classes/en-US.json @@ -24,7 +24,8 @@ "subtitle": null, "title": "Explain the concept of inheritance in ES2015 classes", "topics": [ - "javascript" + "javascript", + "oop" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-the-concept-of-inheritance-in-es2015-classes/en-US.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-partial-application/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-partial-application/en-US.json index 0034d1533..d4d68c988 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-partial-application/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-partial-application/en-US.json @@ -24,6 +24,7 @@ "subtitle": null, "title": "Explain the concept of partial application", "topics": [ + "closure", "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-the-concept-of-partial-application/en-US.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-the-prototype-pattern/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-the-prototype-pattern/en-US.json index a17e83832..e15566883 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-the-prototype-pattern/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-the-prototype-pattern/en-US.json @@ -24,7 +24,8 @@ "subtitle": null, "title": "Explain the concept of the Prototype pattern", "topics": [ - "javascript" + "javascript", + "oop" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-the-concept-of-the-prototype-pattern/en-US.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-the-web-socket-api/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-the-web-socket-api/en-US.json index e69e31c29..7171981f9 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-the-web-socket-api/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-the-web-socket-api/en-US.json @@ -25,7 +25,7 @@ "title": "Explain the concept of the Web Socket API", "topics": [ "javascript", - "network" + "networking" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-the-concept-of-the-web-socket-api/en-US.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-this-binding-in-event-handlers/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-this-binding-in-event-handlers/en-US.json index b058ca4c8..3686d8c8e 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-this-binding-in-event-handlers/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-the-concept-of-this-binding-in-event-handlers/en-US.json @@ -24,6 +24,8 @@ "subtitle": null, "title": "Explain the concept of `this` binding in event handlers", "topics": [ + "closure", + "web-api", "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-the-concept-of-this-binding-in-event-handlers/en-US.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/explain-the-difference-between-classical-inheritance-and-prototypal-inheritance/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-the-difference-between-classical-inheritance-and-prototypal-inheritance/en-US.json index 710a352ce..ee72329e8 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-the-difference-between-classical-inheritance-and-prototypal-inheritance/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-the-difference-between-classical-inheritance-and-prototypal-inheritance/en-US.json @@ -24,7 +24,8 @@ "subtitle": null, "title": "Explain the difference between classical inheritance and prototypal inheritance", "topics": [ - "javascript" + "javascript", + "oop" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-the-difference-between-classical-inheritance-and-prototypal-inheritance/en-US.mdx" }, diff --git a/apps/web/src/__generated__/questions/quiz/explain-the-difference-between-documentqueryselector-and-documentgetelementbyid/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-the-difference-between-documentqueryselector-and-documentgetelementbyid/en-US.json index d89360301..6b48bcd4a 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-the-difference-between-documentqueryselector-and-documentgetelementbyid/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-the-difference-between-documentqueryselector-and-documentgetelementbyid/en-US.json @@ -24,6 +24,7 @@ "subtitle": null, "title": "Explain the difference between `document.querySelector()` and `document.getElementById()`", "topics": [ + "web-api", "javascript", "html" ], diff --git a/apps/web/src/__generated__/questions/quiz/explain-the-difference-between-synchronous-and-asynchronous-functions/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-the-difference-between-synchronous-and-asynchronous-functions/en-US.json index 08fc715d7..6480c8753 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-the-difference-between-synchronous-and-asynchronous-functions/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-the-difference-between-synchronous-and-asynchronous-functions/en-US.json @@ -24,6 +24,7 @@ "subtitle": null, "title": "Explain the difference between synchronous and asynchronous functions in JavaScript", "topics": [ + "async", "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-the-difference-between-synchronous-and-asynchronous-functions/en-US.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/explain-the-difference-between-synchronous-and-asynchronous-functions/pt-BR.json b/apps/web/src/__generated__/questions/quiz/explain-the-difference-between-synchronous-and-asynchronous-functions/pt-BR.json index 960ad17ca..b09261a61 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-the-difference-between-synchronous-and-asynchronous-functions/pt-BR.json +++ b/apps/web/src/__generated__/questions/quiz/explain-the-difference-between-synchronous-and-asynchronous-functions/pt-BR.json @@ -24,6 +24,7 @@ "subtitle": null, "title": "Explique a diferença entre funções síncronas e assíncronas", "topics": [ + "async", "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-the-difference-between-synchronous-and-asynchronous-functions/pt-BR.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/explain-the-difference-between-synchronous-and-asynchronous-functions/zh-CN.json b/apps/web/src/__generated__/questions/quiz/explain-the-difference-between-synchronous-and-asynchronous-functions/zh-CN.json index 1a6c8f660..75b6ea521 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-the-difference-between-synchronous-and-asynchronous-functions/zh-CN.json +++ b/apps/web/src/__generated__/questions/quiz/explain-the-difference-between-synchronous-and-asynchronous-functions/zh-CN.json @@ -24,6 +24,7 @@ "subtitle": null, "title": "解释同步函数和异步函数之间的差异", "topics": [ + "async", "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-the-difference-between-synchronous-and-asynchronous-functions/zh-CN.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/explain-the-different-states-of-a-promise/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-the-different-states-of-a-promise/en-US.json index 1ab32f5e7..87b87ef66 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-the-different-states-of-a-promise/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-the-different-states-of-a-promise/en-US.json @@ -24,6 +24,7 @@ "subtitle": null, "title": "Explain the different states of a Promise", "topics": [ + "async", "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-the-different-states-of-a-promise/en-US.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/explain-the-different-ways-the-this-keyword-can-be-bound/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-the-different-ways-the-this-keyword-can-be-bound/en-US.json index c89f6b39d..a95392c97 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-the-different-ways-the-this-keyword-can-be-bound/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-the-different-ways-the-this-keyword-can-be-bound/en-US.json @@ -24,6 +24,7 @@ "subtitle": null, "title": "Explain the different ways the `this` keyword can be bound", "topics": [ + "closure", "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-the-different-ways-the-this-keyword-can-be-bound/en-US.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/explain-the-event-phases-in-a-browser/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-the-event-phases-in-a-browser/en-US.json index 4eb46b28f..62a284893 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-the-event-phases-in-a-browser/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-the-event-phases-in-a-browser/en-US.json @@ -24,6 +24,7 @@ "subtitle": null, "title": "Explain the event phases in a browser", "topics": [ + "browser", "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-the-event-phases-in-a-browser/en-US.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/explain-the-same-origin-policy-with-regards-to-javascript/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-the-same-origin-policy-with-regards-to-javascript/en-US.json index 9c268988f..36e137a76 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-the-same-origin-policy-with-regards-to-javascript/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-the-same-origin-policy-with-regards-to-javascript/en-US.json @@ -25,7 +25,7 @@ "title": "Explain the same-origin policy with regards to JavaScript", "topics": [ "javascript", - "network", + "networking", "security" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-the-same-origin-policy-with-regards-to-javascript/en-US.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/explain-the-same-origin-policy-with-regards-to-javascript/pt-BR.json b/apps/web/src/__generated__/questions/quiz/explain-the-same-origin-policy-with-regards-to-javascript/pt-BR.json index 14252749d..1facb7e8a 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-the-same-origin-policy-with-regards-to-javascript/pt-BR.json +++ b/apps/web/src/__generated__/questions/quiz/explain-the-same-origin-policy-with-regards-to-javascript/pt-BR.json @@ -25,7 +25,7 @@ "title": "Explique a política de mesma origem em relação ao JavaScript", "topics": [ "javascript", - "network", + "networking", "security" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-the-same-origin-policy-with-regards-to-javascript/pt-BR.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/explain-the-same-origin-policy-with-regards-to-javascript/zh-CN.json b/apps/web/src/__generated__/questions/quiz/explain-the-same-origin-policy-with-regards-to-javascript/zh-CN.json index bf5660f2f..cfd6f0447 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-the-same-origin-policy-with-regards-to-javascript/zh-CN.json +++ b/apps/web/src/__generated__/questions/quiz/explain-the-same-origin-policy-with-regards-to-javascript/zh-CN.json @@ -25,7 +25,7 @@ "title": "解释与JavaScript有关的同源策略。", "topics": [ "javascript", - "network", + "networking", "security" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-the-same-origin-policy-with-regards-to-javascript/zh-CN.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/explain-why-the-following-doesnt-work-as-an-iife-function-foo--what-needs-to-be-changed-to-properly-make-it-an-iife/en-US.json b/apps/web/src/__generated__/questions/quiz/explain-why-the-following-doesnt-work-as-an-iife-function-foo--what-needs-to-be-changed-to-properly-make-it-an-iife/en-US.json index c1d43808e..755ae955b 100644 --- a/apps/web/src/__generated__/questions/quiz/explain-why-the-following-doesnt-work-as-an-iife-function-foo--what-needs-to-be-changed-to-properly-make-it-an-iife/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/explain-why-the-following-doesnt-work-as-an-iife-function-foo--what-needs-to-be-changed-to-properly-make-it-an-iife/en-US.json @@ -22,11 +22,11 @@ "similarQuestions": [], "slug": "explain-why-the-following-doesnt-work-as-an-iife-function-foo--what-needs-to-be-changed-to-properly-make-it-an-iife", "subtitle": null, - "title": "Explain why the following doesn't work as an IIFE: `function foo(){ }();`. What needs to be changed to properly make it an IIFE?", + "title": "Explain why the following doesn't work as an IIFE: `function foo(){}();`. What needs to be changed to properly make it an IIFE?", "topics": [ "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/explain-why-the-following-doesnt-work-as-an-iife-function-foo--what-needs-to-be-changed-to-properly-make-it-an-iife/en-US.mdx" }, - "solution": "var Component=(()=>{var h=Object.create;var a=Object.defineProperty;var p=Object.getOwnPropertyDescriptor;var u=Object.getOwnPropertyNames;var f=Object.getPrototypeOf,m=Object.prototype.hasOwnProperty;var x=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),y=(t,e)=>{for(var o in e)a(t,o,{get:e[o],enumerable:!0})},c=(t,e,o,i)=>{if(e&&typeof e==\"object\"||typeof e==\"function\")for(let r of u(e))!m.call(t,r)&&r!==o&&a(t,r,{get:()=>e[r],enumerable:!(i=p(e,r))||i.enumerable});return t};var v=(t,e,o)=>(o=t!=null?h(f(t)):{},c(e||!t||!t.__esModule?a(o,\"default\",{value:t,enumerable:!0}):o,t)),I=t=>c(a({},\"__esModule\",{value:!0}),t);var d=x((k,s)=>{s.exports=_jsx_runtime});var E={};y(E,{default:()=>b,frontmatter:()=>g});var n=v(d()),g={title:\"Explain why the following doesn't work as an IIFE: `function foo(){ }();`. What needs to be changed to properly make it an IIFE?\"};function l(t){let e=Object.assign({h2:\"h2\",p:\"p\",code:\"code\",hr:\"hr\",h3:\"h3\",pre:\"pre\",ul:\"ul\",li:\"li\",a:\"a\"},t.components);return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(e.h2,{children:\"TL;DR\"}),`\n`,(0,n.jsxs)(e.p,{children:[\"The code \",(0,n.jsx)(e.code,{children:\"function foo(){ }();\"}),\" doesn't work as an Immediately Invoked Function Expression (IIFE) because the JavaScript parser treats \",(0,n.jsx)(e.code,{children:\"function foo(){ }\"}),\" as a function declaration, not an expression. To make it an IIFE, you need to wrap the function in parentheses to turn it into a function expression: \",(0,n.jsx)(e.code,{children:\"(function foo(){ })();\"}),\".\"]}),`\n`,(0,n.jsx)(e.hr,{}),`\n`,(0,n.jsx)(e.h2,{children:\"Why the code doesn't work as an IIFE\"}),`\n`,(0,n.jsx)(e.h3,{children:\"Function declaration vs. function expression\"}),`\n`,(0,n.jsxs)(e.p,{children:[\"In JavaScript, a function declaration and a function expression are treated differently by the parser. The code \",(0,n.jsx)(e.code,{children:\"function foo(){ }\"}),\" is interpreted as a function declaration. Function declarations are not immediately invoked; they are hoisted to the top of their scope and can be called later in the code.\"]}),`\n`,(0,n.jsx)(e.h3,{children:\"Syntax error\"}),`\n`,(0,n.jsxs)(e.p,{children:[\"When you try to immediately invoke a function declaration by adding \",(0,n.jsx)(e.code,{children:\"();\"}),\" at the end, it results in a syntax error because the parser expects a function expression to be invoked immediately, not a declaration.\"]}),`\n`,(0,n.jsx)(e.h2,{children:\"How to properly make it an IIFE\"}),`\n`,(0,n.jsx)(e.h3,{children:\"Wrapping in parentheses\"}),`\n`,(0,n.jsx)(e.p,{children:\"To convert the function declaration into a function expression, you need to wrap the entire function in parentheses. This tells the JavaScript parser to treat it as an expression. Here is the corrected code:\"}),`\n`,(0,n.jsx)(e.pre,{children:(0,n.jsx)(e.code,{className:\"language-javascript\",children:`(function foo() {})();\n`})}),`\n`,(0,n.jsx)(e.h3,{children:\"Alternative syntax\"}),`\n`,(0,n.jsx)(e.p,{children:\"You can also use an alternative syntax by placing the parentheses after the function expression:\"}),`\n`,(0,n.jsx)(e.pre,{children:(0,n.jsx)(e.code,{className:\"language-javascript\",children:`(function foo() {})();\n`})}),`\n`,(0,n.jsx)(e.p,{children:\"Both of these syntaxes are valid and will correctly create an IIFE.\"}),`\n`,(0,n.jsx)(e.h2,{children:\"Further reading\"}),`\n`,(0,n.jsxs)(e.ul,{children:[`\n`,(0,n.jsx)(e.li,{children:(0,n.jsx)(e.a,{href:\"https://developer.mozilla.org/en-US/docs/Glossary/IIFE\",children:\"MDN Web Docs: IIFE\"})}),`\n`,(0,n.jsx)(e.li,{children:(0,n.jsx)(e.a,{href:\"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/function\",children:\"JavaScript Function Expressions\"})}),`\n`,(0,n.jsx)(e.li,{children:(0,n.jsx)(e.a,{href:\"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function\",children:\"JavaScript Function Declarations\"})}),`\n`]})]})}function F(t={}){let{wrapper:e}=t.components||{};return e?(0,n.jsx)(e,Object.assign({},t,{children:(0,n.jsx)(l,t)})):l(t)}var b=F;return I(E);})();\n;return Component;" + "solution": "var Component=(()=>{var h=Object.create;var a=Object.defineProperty;var p=Object.getOwnPropertyDescriptor;var u=Object.getOwnPropertyNames;var f=Object.getPrototypeOf,m=Object.prototype.hasOwnProperty;var x=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),y=(t,e)=>{for(var o in e)a(t,o,{get:e[o],enumerable:!0})},c=(t,e,o,i)=>{if(e&&typeof e==\"object\"||typeof e==\"function\")for(let r of u(e))!m.call(t,r)&&r!==o&&a(t,r,{get:()=>e[r],enumerable:!(i=p(e,r))||i.enumerable});return t};var v=(t,e,o)=>(o=t!=null?h(f(t)):{},c(e||!t||!t.__esModule?a(o,\"default\",{value:t,enumerable:!0}):o,t)),I=t=>c(a({},\"__esModule\",{value:!0}),t);var d=x((k,s)=>{s.exports=_jsx_runtime});var E={};y(E,{default:()=>b,frontmatter:()=>g});var n=v(d()),g={title:\"Explain why the following doesn't work as an IIFE: `function foo(){}();`. What needs to be changed to properly make it an IIFE?\"};function l(t){let e=Object.assign({h2:\"h2\",p:\"p\",code:\"code\",hr:\"hr\",h3:\"h3\",pre:\"pre\",ul:\"ul\",li:\"li\",a:\"a\"},t.components);return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(e.h2,{children:\"TL;DR\"}),`\n`,(0,n.jsxs)(e.p,{children:[\"The code \",(0,n.jsx)(e.code,{children:\"function foo(){}();\"}),\" doesn't work as an Immediately Invoked Function Expression (IIFE) because the JavaScript parser treats \",(0,n.jsx)(e.code,{children:\"function foo(){}\"}),\" as a function declaration, not an expression. To make it an IIFE, you need to wrap the function in parentheses to turn it into a function expression: \",(0,n.jsx)(e.code,{children:\"(function foo(){})();\"}),\".\"]}),`\n`,(0,n.jsx)(e.hr,{}),`\n`,(0,n.jsx)(e.h2,{children:\"Why the code doesn't work as an IIFE\"}),`\n`,(0,n.jsx)(e.h3,{children:\"Function declaration vs. function expression\"}),`\n`,(0,n.jsxs)(e.p,{children:[\"In JavaScript, a function declaration and a function expression are treated differently by the parser. The code \",(0,n.jsx)(e.code,{children:\"function foo(){}\"}),\" is interpreted as a function declaration. Function declarations are not immediately invoked; they are hoisted to the top of their scope and can be called later in the code.\"]}),`\n`,(0,n.jsx)(e.h3,{children:\"Syntax error\"}),`\n`,(0,n.jsxs)(e.p,{children:[\"When you try to immediately invoke a function declaration by adding \",(0,n.jsx)(e.code,{children:\"();\"}),\" at the end, it results in a syntax error because the parser expects a function expression to be invoked immediately, not a declaration.\"]}),`\n`,(0,n.jsx)(e.h2,{children:\"How to properly make it an IIFE\"}),`\n`,(0,n.jsx)(e.h3,{children:\"Wrapping in parentheses\"}),`\n`,(0,n.jsx)(e.p,{children:\"To convert the function declaration into a function expression, you need to wrap the function declaration in parentheses. This tells the JavaScript parser to treat it as an expression. Here is the corrected code:\"}),`\n`,(0,n.jsx)(e.pre,{children:(0,n.jsx)(e.code,{className:\"language-javascript\",children:`(function foo(){})();\n`})}),`\n`,(0,n.jsx)(e.h3,{children:\"Alternative syntax\"}),`\n`,(0,n.jsx)(e.p,{children:\"You can also use an alternative syntax by placing the parentheses around the original line:\"}),`\n`,(0,n.jsx)(e.pre,{children:(0,n.jsx)(e.code,{className:\"language-javascript\",children:`(function foo(){}());\n`})}),`\n`,(0,n.jsx)(e.p,{children:\"Both of these syntaxes are valid and will correctly create an IIFE.\"}),`\n`,(0,n.jsx)(e.h2,{children:\"Further reading\"}),`\n`,(0,n.jsxs)(e.ul,{children:[`\n`,(0,n.jsx)(e.li,{children:(0,n.jsx)(e.a,{href:\"https://developer.mozilla.org/en-US/docs/Glossary/IIFE\",children:\"MDN Web Docs: IIFE\"})}),`\n`,(0,n.jsx)(e.li,{children:(0,n.jsx)(e.a,{href:\"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/function\",children:\"JavaScript Function Expressions\"})}),`\n`,(0,n.jsx)(e.li,{children:(0,n.jsx)(e.a,{href:\"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/function\",children:\"JavaScript Function Declarations\"})}),`\n`]})]})}function F(t={}){let{wrapper:e}=t.components||{};return e?(0,n.jsx)(e,Object.assign({},t,{children:(0,n.jsx)(l,t)})):l(t)}var b=F;return I(E);})();\n;return Component;" } \ No newline at end of file diff --git a/apps/web/src/__generated__/questions/quiz/how-can-closures-be-used-to-create-private-variables/en-US.json b/apps/web/src/__generated__/questions/quiz/how-can-closures-be-used-to-create-private-variables/en-US.json index e911f3f01..f7b07d52f 100644 --- a/apps/web/src/__generated__/questions/quiz/how-can-closures-be-used-to-create-private-variables/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/how-can-closures-be-used-to-create-private-variables/en-US.json @@ -24,6 +24,7 @@ "subtitle": null, "title": "How can closures be used to create private variables?", "topics": [ + "closure", "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/how-can-closures-be-used-to-create-private-variables/en-US.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/how-can-you-optimize-dom-manipulation-for-better-performance/en-US.json b/apps/web/src/__generated__/questions/quiz/how-can-you-optimize-dom-manipulation-for-better-performance/en-US.json index 0557140b5..a1bb2ddff 100644 --- a/apps/web/src/__generated__/questions/quiz/how-can-you-optimize-dom-manipulation-for-better-performance/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/how-can-you-optimize-dom-manipulation-for-better-performance/en-US.json @@ -24,6 +24,7 @@ "subtitle": null, "title": "How can you optimize DOM manipulation for better performance?", "topics": [ + "web-api", "javascript", "performance" ], diff --git a/apps/web/src/__generated__/questions/quiz/how-can-you-optimize-network-requests-for-better-performance/en-US.json b/apps/web/src/__generated__/questions/quiz/how-can-you-optimize-network-requests-for-better-performance/en-US.json index abf41f83f..7976941b8 100644 --- a/apps/web/src/__generated__/questions/quiz/how-can-you-optimize-network-requests-for-better-performance/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/how-can-you-optimize-network-requests-for-better-performance/en-US.json @@ -25,6 +25,7 @@ "title": "How can you optimize network requests for better performance?", "topics": [ "javascript", + "networking", "performance" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/how-can-you-optimize-network-requests-for-better-performance/en-US.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/how-can-you-test-asynchronous-code-in-javascript/en-US.json b/apps/web/src/__generated__/questions/quiz/how-can-you-test-asynchronous-code-in-javascript/en-US.json index 94c8dc652..018b01909 100644 --- a/apps/web/src/__generated__/questions/quiz/how-can-you-test-asynchronous-code-in-javascript/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/how-can-you-test-asynchronous-code-in-javascript/en-US.json @@ -24,6 +24,7 @@ "subtitle": null, "title": "How can you test asynchronous code in JavaScript?", "topics": [ + "async", "javascript", "testing" ], diff --git a/apps/web/src/__generated__/questions/quiz/how-do-currying-and-partial-application-differ-from-each-other/en-US.json b/apps/web/src/__generated__/questions/quiz/how-do-currying-and-partial-application-differ-from-each-other/en-US.json index 6dc64c591..e922194f5 100644 --- a/apps/web/src/__generated__/questions/quiz/how-do-currying-and-partial-application-differ-from-each-other/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/how-do-currying-and-partial-application-differ-from-each-other/en-US.json @@ -24,6 +24,7 @@ "subtitle": null, "title": "How do currying and partial application differ from each other?", "topics": [ + "closure", "javascript" ], "gitHubEditUrl": "https://github.com/yangshun/top-javascript-interview-questions/blob/main/questions/how-do-currying-and-partial-application-differ-from-each-other/en-US.mdx" diff --git a/apps/web/src/__generated__/questions/quiz/how-do-iframe-on-a-page-communicate/en-US.json b/apps/web/src/__generated__/questions/quiz/how-do-iframe-on-a-page-communicate/en-US.json index 7ec619181..f3a8115a7 100644 --- a/apps/web/src/__generated__/questions/quiz/how-do-iframe-on-a-page-communicate/en-US.json +++ b/apps/web/src/__generated__/questions/quiz/how-do-iframe-on-a-page-communicate/en-US.json @@ -24,6 +24,7 @@ "subtitle": null, "title": "How do `