fix: update/add links to website (#8729)

---------

Co-authored-by: Ben McCann <322311+benmccann@users.noreply.github.com>
Co-authored-by: Simon H <5968653+dummdidumm@users.noreply.github.com>
Co-authored-by: Simon Holthausen <simon.holthausen@vercel.com>
pull/8785/head
Puru Vijay 2 years ago committed by GitHub
parent 963cbcdb06
commit 78749101e7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -115,6 +115,9 @@ function validate_options(options, warnings) {
}
/**
* `compile` takes your component source code, and turns it into a JavaScript module that exports a class.
*
* https://svelte.dev/docs/svelte-compiler#svelte-compile
* @param {string} source
* @param {import('../interfaces.js').CompileOptions} options
*/

@ -257,6 +257,9 @@ export class Parser {
}
/**
* The parse function parses a component, returning only its abstract syntax tree.
*
* https://svelte.dev/docs/svelte-compiler#svelte-parse
* @param {string} template
* @param {import('../interfaces.js').ParserOptions} options
* @returns {import('../interfaces.js').Ast}

@ -327,6 +327,10 @@ async function process_markup(process, source) {
}
/**
* The preprocess function provides convenient hooks for arbitrarily transforming component source code.
* For example, it can be used to convert a <style lang="sass"> block into vanilla CSS.
*
* https://svelte.dev/docs/svelte-compiler#svelte-preprocess
* @param {string} source
* @param {import('./public.js').PreprocessorGroup | import('./public.js').PreprocessorGroup[]} preprocessor
* @param {{ filename?: string }} [options]

@ -1,6 +1,6 @@
// The `foreign` namespace covers all DOM implementations that aren't HTML5.
// It opts out of HTML5-specific a11y checks and case-insensitive attribute names.
export const foreign = 'https://svelte.dev/docs#template-syntax-svelte-options';
export const foreign = 'https://svelte.dev/docs/special-elements#svelte-options';
export const html = 'http://www.w3.org/1999/xhtml';
export const mathml = 'http://www.w3.org/1998/Math/MathML';
export const svg = 'http://www.w3.org/2000/svg';

@ -24,7 +24,7 @@
* }
* ```
*
* Docs: https://svelte.dev/docs#template-syntax-element-directives-use-action
* Docs: https://svelte.dev/docs/svelte-action
*/
export interface ActionReturn<
Parameter = never,
@ -55,7 +55,7 @@ export interface ActionReturn<
* You can return an object with methods `update` and `destroy` from the function and type which additional attributes and events it has.
* See interface `ActionReturn` for more details.
*
* Docs: https://svelte.dev/docs#template-syntax-element-directives-use-action
* Docs: https://svelte.dev/docs/svelte-action
*/
export interface Action<
Element = HTMLElement,

@ -2,6 +2,10 @@ import { cubicOut } from '../easing/index.js';
import { is_function } from '../internal/index.js';
/**
* The flip function calculates the start and end position of an element and animates between them, translating the x and y values.
* `flip` stands for [First, Last, Invert, Play](https://aerotwist.com/blog/flip-your-animations/).
*
* https://svelte.dev/docs/svelte-animate#flip
* @param {Element} node
* @param {{ from: DOMRect; to: DOMRect }} fromTo
* @param {import('./public.js').FlipParams} params

@ -5,6 +5,7 @@ Distributed under MIT License https://github.com/mattdesl/eases/blob/master/LICE
export { identity as linear } from '../internal/index.js';
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -15,6 +16,7 @@ export function backInOut(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -24,6 +26,7 @@ export function backIn(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -33,6 +36,7 @@ export function backOut(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -54,6 +58,7 @@ export function bounceOut(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -62,6 +67,7 @@ export function bounceInOut(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -70,6 +76,7 @@ export function bounceIn(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -79,6 +86,7 @@ export function circInOut(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -87,6 +95,7 @@ export function circIn(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -95,6 +104,7 @@ export function circOut(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -103,6 +113,7 @@ export function cubicInOut(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -111,6 +122,7 @@ export function cubicIn(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -120,6 +132,7 @@ export function cubicOut(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -133,6 +146,7 @@ export function elasticInOut(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -141,6 +155,7 @@ export function elasticIn(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -149,6 +164,7 @@ export function elasticOut(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -161,6 +177,7 @@ export function expoInOut(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -169,6 +186,7 @@ export function expoIn(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -177,6 +195,7 @@ export function expoOut(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -188,6 +207,7 @@ export function quadInOut(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -196,6 +216,7 @@ export function quadIn(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -204,6 +225,7 @@ export function quadOut(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -212,6 +234,7 @@ export function quartInOut(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -220,6 +243,7 @@ export function quartIn(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -228,6 +252,7 @@ export function quartOut(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -237,6 +262,7 @@ export function quintInOut(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -245,6 +271,7 @@ export function quintIn(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -253,6 +280,7 @@ export function quintOut(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -261,6 +289,7 @@ export function sineInOut(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/
@ -271,6 +300,7 @@ export function sineIn(t) {
}
/**
* https://svelte.dev/docs/svelte-easing
* @param {number} t
* @returns {number}
*/

@ -17,7 +17,7 @@ export function get_current_component() {
*
* The first time the callback runs will be before the initial `onMount`
*
* https://svelte.dev/docs#run-time-svelte-beforeupdate
* https://svelte.dev/docs/svelte#beforeupdate
* @param {() => any} fn
* @returns {void}
*/
@ -34,7 +34,7 @@ export function beforeUpdate(fn) {
*
* `onMount` does not run inside a [server-side component](/docs#run-time-server-side-component-api).
*
* https://svelte.dev/docs#run-time-svelte-onmount
* https://svelte.dev/docs/svelte#onmount
* @template T
* @param {() => import('./private.js').NotFunction<T> | Promise<import('./private.js').NotFunction<T>> | (() => any)} fn
* @returns {void}
@ -47,6 +47,8 @@ export function onMount(fn) {
* Schedules a callback to run immediately after the component has been updated.
*
* The first time the callback runs will be after the initial `onMount`
*
* https://svelte.dev/docs/svelte#afterupdate
* @param {() => any} fn
* @returns {void}
*/
@ -60,7 +62,7 @@ export function afterUpdate(fn) {
* Out of `onMount`, `beforeUpdate`, `afterUpdate` and `onDestroy`, this is the
* only one that runs inside a server-side component.
*
* https://svelte.dev/docs#run-time-svelte-ondestroy
* https://svelte.dev/docs/svelte#ondestroy
* @param {() => any} fn
* @returns {void}
*/
@ -87,7 +89,7 @@ export function onDestroy(fn) {
* }>();
* ```
*
* https://svelte.dev/docs#run-time-svelte-createeventdispatcher
* https://svelte.dev/docs/svelte#createeventdispatcher
* @template {Record<string, any>} [EventMap=any]
* @returns {import('./public.js').EventDispatcher<EventMap>}
*/
@ -115,7 +117,7 @@ export function createEventDispatcher() {
*
* Like lifecycle functions, this must be called during component initialisation.
*
* https://svelte.dev/docs#run-time-svelte-setcontext
* https://svelte.dev/docs/svelte#setcontext
* @template T
* @param {any} key
* @param {T} context
@ -130,7 +132,7 @@ export function setContext(key, context) {
* Retrieves the context that belongs to the closest parent component with the specified `key`.
* Must be called during component initialisation.
*
* https://svelte.dev/docs#run-time-svelte-getcontext
* https://svelte.dev/docs/svelte#getcontext
* @template T
* @param {any} key
* @returns {T}
@ -144,7 +146,7 @@ export function getContext(key) {
* Must be called during component initialisation. Useful, for example, if you
* programmatically create a component and want to pass the existing context to it.
*
* https://svelte.dev/docs#run-time-svelte-getallcontexts
* https://svelte.dev/docs/svelte#getallcontexts
* @template {Map<any, any>} [T=Map<any, any>]
* @returns {T}
*/
@ -156,7 +158,7 @@ export function getAllContexts() {
* Checks whether a given `key` has been set in the context of a parent component.
* Must be called during component initialisation.
*
* https://svelte.dev/docs#run-time-svelte-hascontext
* https://svelte.dev/docs/svelte#hascontext
* @param {any} key
* @returns {boolean}
*/

@ -107,6 +107,8 @@ export function subscribe(store, ...callbacks) {
/**
* Get the current value from a store by subscribing and immediately unsubscribing.
*
* https://svelte.dev/docs/svelte-store#get
* @template T
* @param {import('../store/public.js').Readable<T>} store
* @returns {T}

@ -46,6 +46,9 @@ function tick_spring(ctx, last_value, current_value, target_value) {
}
/**
* The spring function in Svelte creates a store whose value is animated, with a motion that simulates the behavior of a spring. This means when the value changes, instead of transitioning at a steady rate, it "bounces" like a spring would, depending on the physics parameters provided. This adds a level of realism to the transitions and can enhance the user experience.
*
* https://svelte.dev/docs/svelte-motion#spring
* @template T
* @param {T} [value]
* @param {import('./private.js').SpringOpts} [opts]

@ -45,6 +45,9 @@ function get_interpolator(a, b) {
}
/**
* A tweened store in Svelte is a special type of store that provides smooth transitions between state values over time.
*
* https://svelte.dev/docs/svelte-motion#tweened
* @template T
* @param {T} [value]
* @param {import('./private.js').TweenedOptions<T>} [defaults]

@ -11,6 +11,8 @@ const subscriber_queue = [];
/**
* Creates a `Readable` store that allows reading by subscription.
*
* https://svelte.dev/docs/svelte-store#readable
* @template T
* @param {T} [value] initial value
* @param {import('./public.js').StartStopNotifier<T>} [start]
@ -24,6 +26,8 @@ export function readable(value, start) {
/**
* Create a `Writable` store that allows both updating and reading by subscription.
*
* https://svelte.dev/docs/svelte-store#writable
* @template T
* @param {T} [value] initial value
* @param {import('./public.js').StartStopNotifier<T>} [start]
@ -93,6 +97,7 @@ export function writable(value, start = noop) {
* Derived value store by synchronizing one or more readable stores and
* applying an aggregation function over its input values.
*
* https://svelte.dev/docs/svelte-store#derived
* @template {import('./private.js').Stores} S
* @template T
* @overload
@ -106,6 +111,7 @@ export function writable(value, start = noop) {
* Derived value store by synchronizing one or more readable stores and
* applying an aggregation function over its input values.
*
* https://svelte.dev/docs/svelte-store#derived
* @template {import('./private.js').Stores} S
* @template T
* @overload
@ -179,6 +185,7 @@ export function derived(stores, fn, initial_value) {
/**
* Takes a store and returns a new one derived from the old one that is readable.
*
* https://svelte.dev/docs/svelte-store#readonly
* @template T
* @param {import('./public.js').Readable<T>} store - store to make readonly
* @returns {import('./public.js').Readable<T>}

@ -2,6 +2,9 @@ import { cubicOut, cubicInOut, linear } from '../easing/index.js';
import { assign, split_css_unit, is_function } from '../internal/index.js';
/**
* Animates a `blur` filter alongside an element's opacity.
*
* https://svelte.dev/docs/svelte-transition#blur
* @param {Element} node
* @param {import('./public').BlurParams} [params]
* @returns {import('./public').TransitionConfig}
@ -24,6 +27,9 @@ export function blur(
}
/**
* Animates the opacity of an element from 0 to the current opacity for `in` transitions and from the current opacity to 0 for `out` transitions.
*
* https://svelte.dev/docs/svelte-transition#fade
* @param {Element} node
* @param {import('./public').FadeParams} [params]
* @returns {import('./public').TransitionConfig}
@ -39,6 +45,9 @@ export function fade(node, { delay = 0, duration = 400, easing = linear } = {})
}
/**
* Animates the x and y positions and the opacity of an element. `in` transitions animate from the provided values, passed as parameters to the element's default values. `out` transitions animate from the element's default values to the provided values.
*
* https://svelte.dev/docs/svelte-transition#fly
* @param {Element} node
* @param {import('./public').FlyParams} [params]
* @returns {import('./public').TransitionConfig}
@ -64,6 +73,9 @@ export function fly(
}
/**
* Slides an element in and out.
*
* https://svelte.dev/docs/svelte-transition#slide
* @param {Element} node
* @param {import('./public').SlideParams} [params]
* @returns {import('./public').TransitionConfig}
@ -105,6 +117,9 @@ export function slide(node, { delay = 0, duration = 400, easing = cubicOut, axis
}
/**
* Animates the opacity and scale of an element. `in` transitions animate from an element's current (default) values to the provided values, passed as parameters. `out` transitions animate from the provided values to an element's default values.
*
* https://svelte.dev/docs/svelte-transition#scale
* @param {Element} node
* @param {import('./public').ScaleParams} [params]
* @returns {import('./public').TransitionConfig}
@ -130,6 +145,9 @@ export function scale(
}
/**
* Animates the stroke of an SVG element, like a snake in a tube. `in` transitions begin with the path invisible and draw the path to the screen over time. `out` transitions start in a visible state and gradually erase the path. `draw` only works with elements that have a `getTotalLength` method, like `<path>` and `<polyline>`.
*
* https://svelte.dev/docs/svelte-transition#draw
* @param {SVGElement & { getTotalLength(): number }} node
* @param {import('./public').DrawParams} [params]
* @returns {import('./public').TransitionConfig}
@ -161,6 +179,9 @@ export function draw(node, { delay = 0, speed, duration, easing = cubicInOut } =
}
/**
* The `crossfade` function creates a pair of [transitions](/docs#template-syntax-element-directives-transition-fn) called `send` and `receive`. When an element is 'sent', it looks for a corresponding element being 'received', and generates a transition that transforms the element to its counterpart's position and fades it out. When an element is 'received', the reverse happens. If there is no counterpart, the `fallback` transition is used.
*
* https://svelte.dev/docs/svelte-transition#crossfade
* @param {import('./public').CrossfadeParams & {
* fallback?: (node: Element, params: import('./public').CrossfadeParams, intro: boolean) => import('./public').TransitionConfig;
* }} params

@ -1,4 +1,9 @@
// generated during release, do not modify
/** @type {string} */
/**
* The current version, as set in package.json.
*
* https://svelte.dev/docs/svelte-compiler#svelte-version
* @type {string}
*/
export const VERSION = '4.0.0-next.2';

@ -18,8 +18,8 @@ function create_fragment(ctx) {
return {
c() {
svg = document.createElementNS("https://svelte.dev/docs#template-syntax-svelte-options", "svg");
img = document.createElementNS("https://svelte.dev/docs#template-syntax-svelte-options", "img");
svg = document.createElementNS("https://svelte.dev/docs/special-elements#svelte-options", "svg");
img = document.createElementNS("https://svelte.dev/docs/special-elements#svelte-options", "img");
this.h();
},
l(nodes) {

Loading…
Cancel
Save