Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit c6106ee

Browse files
committed
Move isWildcard to top of file
1 parent 45eacd3 commit c6106ee

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/index.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,10 @@ function task(): Promise<void> {
2828
return new Promise(resolve => setTimeout(resolve, 0))
2929
}
3030

31+
function isWildcard(accept: string | null) {
32+
return accept && !!accept.split(',').find(x => x.match(/^\s*\*\/\*/))
33+
}
34+
3135
async function handleData(el: IncludeFragmentElement) {
3236
observer.unobserve(el)
3337
return getData(el).then(
@@ -108,10 +112,6 @@ function fetchDataWithEvents(el: IncludeFragmentElement) {
108112
)
109113
}
110114

111-
function isWildcard(accept: string | null) {
112-
return accept && !!accept.split(',').find(x => x.match(/^\s*\*\/\*/))
113-
}
114-
115115
export default class IncludeFragmentElement extends HTMLElement {
116116
static get observedAttributes(): string[] {
117117
return ['src', 'loading']

0 commit comments

Comments
 (0)