mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-13 04:48:53 +00:00
feat(core): unused blob management in settings (#9795)
fix AF-2144, PD-2064, PD-2065, PD-2066
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
export { createComponent as createReactComponentFromLit } from './create-component';
|
||||
export * from './lit-portal';
|
||||
export { toReactNode } from './to-react-node';
|
||||
export { templateToString } from './utils';
|
||||
|
||||
9
packages/frontend/component/src/lit-react/utils.ts
Normal file
9
packages/frontend/component/src/lit-react/utils.ts
Normal file
@@ -0,0 +1,9 @@
|
||||
import type { TemplateResult } from 'lit';
|
||||
|
||||
export function templateToString({ strings, values }: TemplateResult): string {
|
||||
return strings.reduce(
|
||||
(result, str, i) =>
|
||||
result + str + (i < values.length ? String(values[i]) : ''),
|
||||
''
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user