mirror of
https://github.com/PretendoNetwork/website.git
synced 2026-09-26 10:36:39 -05:00
fix(eslint): add browser globals
thx @binaryoverload
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
import pluginVue from 'eslint-plugin-vue';
|
||||
import eslintConfig from '@pretendonetwork/eslint-config';
|
||||
import globals from 'globals';
|
||||
import { withNuxt } from './.nuxt/eslint.config.mjs';
|
||||
|
||||
export default withNuxt([
|
||||
@@ -10,6 +11,9 @@ export default withNuxt([
|
||||
languageOptions: {
|
||||
parserOptions: {
|
||||
parser: '@typescript-eslint/parser'
|
||||
},
|
||||
globals: {
|
||||
...globals.browser
|
||||
}
|
||||
},
|
||||
rules: {
|
||||
|
||||
@@ -16,9 +16,7 @@ function handleDropdownButton(dropdown: boolean | string) {
|
||||
const scrollY = ref<number>(0);
|
||||
|
||||
onMounted(() => {
|
||||
// eslint-disable-next-line no-undef -- we're in on mounted so it should be fine
|
||||
window.addEventListener('scroll', () => {
|
||||
// eslint-disable-next-line no-undef -- same here
|
||||
scrollY.value = window.scrollY;
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user