_config.js — svelte Source File
Architecture documentation for _config.js, a javascript file in the svelte codebase. 3 imports, 0 dependents.
Entity Profile
Dependency Diagram
graph LR a83f67c8_2842_a97e_e086_4a92dd84d447["_config.js"] 654af6d6_2570_6860_f8dd_6b6131e1eec4["test.ts"] a83f67c8_2842_a97e_e086_4a92dd84d447 --> 654af6d6_2570_6860_f8dd_6b6131e1eec4 e97e8c41_1b06_4e9a_29f3_64dbb37dee3c["helpers.js"] a83f67c8_2842_a97e_e086_4a92dd84d447 --> e97e8c41_1b06_4e9a_29f3_64dbb37dee3c 968bf0f0_2e69_28c9_a363_08177fdb8e17["create_deferred"] a83f67c8_2842_a97e_e086_4a92dd84d447 --> 968bf0f0_2e69_28c9_a363_08177fdb8e17 style a83f67c8_2842_a97e_e086_4a92dd84d447 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
import { test } from '../../test';
import { create_deferred } from '../../../helpers.js';
/** @type {ReturnType<typeof create_deferred>} */
let deferred;
export default test({
before_test() {
deferred = create_deferred();
},
get props() {
return { thePromise: deferred.promise };
},
html: `
<p>loading...</p>
<p>loading...</p>
`,
test({ assert, component, target }) {
deferred.resolve(42);
return deferred.promise
.then(() => {
assert.htmlEqual(
target.innerHTML,
`
<p>the value is 42</p>
<p>the value is 42</p>
`
);
deferred = create_deferred();
component.thePromise = deferred.promise;
assert.htmlEqual(
target.innerHTML,
`
<p>loading...</p>
<p>loading...</p>
`
);
deferred.reject(new Error('something broke'));
return deferred.promise.catch(() => {});
})
.then(() => {
assert.htmlEqual(
target.innerHTML,
`
<p>oh no! something broke</p>
<p>oh no! something broke</p>
`
);
});
}
});
Domain
Subdomains
Dependencies
Source
Frequently Asked Questions
What does _config.js do?
_config.js is a source file in the svelte codebase, written in javascript. It belongs to the BuildSystem domain, QualityControl subdomain.
What functions are defined in _config.js?
_config.js defines 3 function(s): default.before_test, default.props, default.test.
What does _config.js depend on?
_config.js imports 3 module(s): create_deferred, helpers.js, test.ts.
Where is _config.js in the architecture?
_config.js is located at packages/svelte/tests/runtime-legacy/samples/await-then-catch-multiple/_config.js (domain: BuildSystem, subdomain: QualityControl, directory: packages/svelte/tests/runtime-legacy/samples/await-then-catch-multiple).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free