Skip to content

Commit 839e7e3

Browse files
committed
more accurate name
1 parent 7f0ca11 commit 839e7e3

File tree

5 files changed

+9
-13
lines changed

5 files changed

+9
-13
lines changed

packages/svelte/src/compiler/phases/3-transform/client/visitors/RegularElement.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ import { visit_event_attribute } from './shared/events.js';
2828
import { process_children } from './shared/fragment.js';
2929
import {
3030
build_render_statement,
31-
build_template_literal,
31+
build_template_chunk,
3232
build_update,
3333
build_update_assignment,
3434
escape_inline_expression,
@@ -361,7 +361,7 @@ export function RegularElement(node, context) {
361361
get_states_and_calls(trimmed);
362362

363363
if (states_and_calls && states_and_calls.states === 0) {
364-
let { value, can_inline } = build_template_literal(trimmed, context.visit, child_state);
364+
let { value, can_inline } = build_template_chunk(trimmed, context.visit, child_state);
365365

366366
// if the expression is inlinable we just push it to the template
367367
if (can_inline) {

packages/svelte/src/compiler/phases/3-transform/client/visitors/TitleElement.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
/** @import { AST } from '#compiler' */
22
/** @import { ComponentContext } from '../types' */
33
import * as b from '../../../../utils/builders.js';
4-
import { build_template_literal } from './shared/utils.js';
4+
import { build_template_chunk } from './shared/utils.js';
55

66
/**
77
* @param {AST.TitleElement} node
88
* @param {ComponentContext} context
99
*/
1010
export function TitleElement(node, context) {
11-
const { has_state, value } = build_template_literal(
11+
const { has_state, value } = build_template_chunk(
1212
/** @type {any} */ (node.fragment.nodes),
1313
context.visit,
1414
context.state

packages/svelte/src/compiler/phases/3-transform/client/visitors/shared/element.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import { is_ignored } from '../../../../../state.js';
66
import { get_attribute_expression, is_event_attribute } from '../../../../../utils/ast.js';
77
import * as b from '../../../../../utils/builders.js';
88
import { build_getter, create_derived } from '../../utils.js';
9-
import { build_template_literal, build_update } from './utils.js';
9+
import { build_template_chunk, build_update } from './utils.js';
1010

1111
/**
1212
* @param {Array<AST.Attribute | AST.SpreadAttribute>} attributes
@@ -200,7 +200,7 @@ export function build_attribute_value(value, context) {
200200
};
201201
}
202202

203-
return build_template_literal(value, context.visit, context.state);
203+
return build_template_chunk(value, context.visit, context.state);
204204
}
205205

206206
/**

packages/svelte/src/compiler/phases/3-transform/client/visitors/shared/fragment.js

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
import { is_event_attribute } from '../../../../../utils/ast.js';
55
import * as b from '../../../../../utils/builders.js';
66
import { is_inlinable_attribute } from '../../../../utils.js';
7-
import { build_template_literal, build_update, escape_inline_expression } from './utils.js';
7+
import { build_template_chunk, build_update, escape_inline_expression } from './utils.js';
88

99
/**
1010
* Processes an array of template nodes, joining sibling text/expression nodes
@@ -69,11 +69,7 @@ export function process_children(nodes, initial, is_element, { visit, state }) {
6969
return;
7070
}
7171

72-
const { has_state, has_call, value, can_inline } = build_template_literal(
73-
sequence,
74-
visit,
75-
state
76-
);
72+
const { has_state, has_call, value, can_inline } = build_template_chunk(sequence, visit, state);
7773

7874
if (can_inline) {
7975
skipped += 1;

packages/svelte/src/compiler/phases/3-transform/client/visitors/shared/utils.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ export function escape_inline_expression(node, is_attr) {
6363
* @param {ComponentClientTransformState} state
6464
* @returns {{ value: Expression, has_state: boolean, has_call: boolean, can_inline: boolean }}
6565
*/
66-
export function build_template_literal(values, visit, state) {
66+
export function build_template_chunk(values, visit, state) {
6767
/** @type {Expression[]} */
6868
const expressions = [];
6969

0 commit comments

Comments
 (0)