style: lint

This commit is contained in:
Xmader 2020-09-27 11:45:51 -04:00
parent 43e9780857
commit efa676b921
5 changed files with 5 additions and 4 deletions

View File

@ -78,7 +78,7 @@ const main = (): void => {
// parse mscz data // parse mscz data
const data = new Uint8Array( const data = new Uint8Array(
new Uint8Array(await fetchMscz()) // copy its ArrayBuffer new Uint8Array(await fetchMscz()), // copy its ArrayBuffer
) )
score = await w['WebMscore'].load('mscz', data) score = await w['WebMscore'].load('mscz', data)
await score.generateExcerpts() await score.generateExcerpts()

View File

@ -5,7 +5,7 @@ import scoreinfo from './scoreinfo'
let pdfBlob: Blob let pdfBlob: Blob
const _downloadPDF = async (imgURLs: string[], imgType: 'svg' | 'png', name?: string): Promise<void> => { const _downloadPDF = async (imgURLs: string[], imgType: 'svg' | 'png', name = ''): Promise<void> => {
if (pdfBlob) { if (pdfBlob) {
return saveAs(pdfBlob, `${name}.pdf`) return saveAs(pdfBlob, `${name}.pdf`)
} }

View File

@ -6,7 +6,7 @@ const SITE_KEY = '6Ldxtt8UAAAAALvcRqWTlVOVIB7MmEWwN-zw_9fM'
type token = string; type token = string;
interface GRecaptcha { interface GRecaptcha {
ready (cb: Function): void; ready (cb: () => any): void;
execute (siteKey: string, opts: { action: string }): Promise<token>; execute (siteKey: string, opts: { action: string }): Promise<token>;
} }

View File

@ -5,6 +5,7 @@ const scoreinfo = {
get playerdata (): ScorePlayerData { get playerdata (): ScorePlayerData {
// @ts-ignore // @ts-ignore
// eslint-disable-next-line @typescript-eslint/no-unsafe-return
return window.UGAPP.store.jmuse_settings.score_player return window.UGAPP.store.jmuse_settings.score_player
}, },

View File

@ -2,7 +2,7 @@
import { PDFWorkerMessage } from './worker' import { PDFWorkerMessage } from './worker'
import { PDFWorker } from '../dist/cache/worker' import { PDFWorker } from '../dist/cache/worker'
const scriptUrlFromFunction = (fn: Function): string => { const scriptUrlFromFunction = (fn: () => any): string => {
const blob = new Blob(['(' + fn.toString() + ')()'], { type: 'application/javascript' }) const blob = new Blob(['(' + fn.toString() + ')()'], { type: 'application/javascript' })
return URL.createObjectURL(blob) return URL.createObjectURL(blob)
} }