forked from trent_larson/crowd-funder-for-time-pwa
- Move queryResult and allResult declarations outside switch statement - Change const declarations to let since they're now in outer scope - Remove const declarations from inside case blocks This fixes the 'no-case-declarations' linter errors by ensuring variables are declared in a scope that encompasses all case blocks, preventing potential scoping issues. Note: Type definition errors for external modules remain and should be addressed separately.
19 lines
437 B
JavaScript
19 lines
437 B
JavaScript
// Minimal fs module implementation for browser
|
|
const fs = {
|
|
readFileSync: () => {
|
|
throw new Error("fs.readFileSync is not supported in browser");
|
|
},
|
|
writeFileSync: () => {
|
|
throw new Error("fs.writeFileSync is not supported in browser");
|
|
},
|
|
existsSync: () => false,
|
|
mkdirSync: () => {},
|
|
readdirSync: () => [],
|
|
statSync: () => ({
|
|
isDirectory: () => false,
|
|
isFile: () => false,
|
|
}),
|
|
};
|
|
|
|
export default fs;
|