fix: fix css resources with parameters not loading correctly

This commit is contained in:
liujuping 2022-08-04 19:32:32 +08:00 committed by 林熠
parent 4d6dfe9f57
commit 9a5a04ac95
2 changed files with 4 additions and 2 deletions

View File

@ -4,12 +4,14 @@ import { createDefer } from './create-defer';
import { load, evaluate } from './script';
// API 向下兼容
export { AssetItem, AssetType, AssetLevels, Asset, AssetList, AssetBundle, AssetLevel, AssetsJson } from '@alilc/lowcode-types';
export { AssetType, AssetLevels, Asset, AssetList, AssetBundle, AssetLevel, AssetsJson } from '@alilc/lowcode-types';
export function isAssetItem(obj: any): obj is AssetItem {
return obj && obj.type;
}
export type { AssetItem } from '@alilc/lowcode-types';
export function isAssetBundle(obj: any): obj is AssetBundle {
return obj && obj.type === AssetType.Bundle;
}

View File

@ -1,3 +1,3 @@
export function isCSSUrl(url: string): boolean {
return /\.css$/.test(url);
return /\.css(\?.*)?$/.test(url);
}