1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-11-23 22:36:32 +02:00

Chore: Refactor renderer package: Limit dependency on @joplin/lib and improve type safety (#9701)

This commit is contained in:
Henry Heino
2024-01-18 03:20:10 -08:00
committed by GitHub
parent 352ee6496e
commit f5e1e45f6f
32 changed files with 457 additions and 393 deletions

View File

@@ -0,0 +1,16 @@
import { OptionsResourceModel } from './types';
// Used for tests and when no ResourceModel is provided.
const defaultResourceModel: OptionsResourceModel = {
isResourceUrl: (_url: string) => false,
urlToId: _url => {
throw new Error('Not implemented: urlToId');
},
filename: _url => {
throw new Error('Not implemented: filename');
},
isSupportedImageMimeType: _type => false,
};
export default defaultResourceModel;