Skip to content

Commit

Permalink
fix(clean): removed unneeded imports
Browse files Browse the repository at this point in the history
  • Loading branch information
ThornWalli committed Apr 24, 2024
1 parent 96295dd commit 297edf1
Show file tree
Hide file tree
Showing 44 changed files with 8 additions and 73 deletions.
1 change: 0 additions & 1 deletion playground/components/InfoLayer.vue
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@

<script setup>
import { getStyleDescription } from '#booster/utils/description';
import { useHead, useBoosterFonts } from '#imports';
import BoosterLayer from '#booster/components/BoosterLayer';
import BaseButton from '@/components/base/Button';
const { $getFont } = useBoosterFonts();
Expand Down
2 changes: 0 additions & 2 deletions playground/components/PageHeader.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@
</template>

<script setup>
import { defineOptions } from 'vue';
import PageHeaderMenu from './fragments/PageHeaderMenu';
defineOptions({
Expand Down
1 change: 0 additions & 1 deletion playground/components/PreviewContainer.vue
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
</template>

<script setup>
import { useBoosterFonts } from '#imports';
const { $getFont } = useBoosterFonts();
</script>

Expand Down
1 change: 0 additions & 1 deletion playground/components/WeakHardwareOverlay.vue
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ import BoosterWeakHardwareOverlay from '#booster/components/WeakHardwareOverlay'
import BaseButton from '@/components/base/Button';
import { useBoosterFonts } from '#imports';
const { $getFont } = useBoosterFonts();
defineProps({
text: {
Expand Down
1 change: 0 additions & 1 deletion playground/components/base/Button.vue
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
</template>

<script setup>
import { useBoosterFonts } from '#imports';
const { $getFont } = useBoosterFonts();
defineEmits(['click']);
</script>
Expand Down
1 change: 0 additions & 1 deletion playground/components/base/Headline.vue
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
</template>

<script setup>
import { useBoosterFonts } from '#imports';
const { $getFont } = useBoosterFonts();
</script>

Expand Down
1 change: 0 additions & 1 deletion playground/components/base/LinkList.vue
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
</template>

<script setup>
import { useBoosterFonts } from '#imports';
const { $getFont } = useBoosterFonts();
</script>

Expand Down
3 changes: 0 additions & 3 deletions playground/components/elements/LoaderTest.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,6 @@
</template>

<script setup>
import { ref } from 'vue';
import { onMounted, useBoosterCritical } from '#imports';
const { isCritical } = useBoosterCritical();
const active = ref(false);
Expand Down
1 change: 0 additions & 1 deletion playground/components/elements/ScrollItem.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
</template>

<script setup>
import { useBoosterFonts } from '#imports';
const { $getFont } = useBoosterFonts();
defineProps({
font: {
Expand Down
2 changes: 0 additions & 2 deletions playground/components/fragments/PageHeaderMenu.vue
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,6 @@
</template>

<script setup>
import { watch, computed, ref, onMounted } from 'vue';
import { useRoute } from '#app';
import Headline from '@/components/base/Headline';
import LinkList from '@/components/base/LinkList';
Expand Down
2 changes: 1 addition & 1 deletion playground/components/modules/ImageText.vue
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@

<script setup>
import BoosterPicture from '#booster/components/BoosterPicture';
import { useBoosterFonts } from '#imports';
const { $getFont } = useBoosterFonts();
defineProps({
alignRight: { type: Boolean, default: false },
Expand Down
3 changes: 1 addition & 2 deletions playground/components/modules/Stage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,10 @@
</template>

<script setup>
import { onMounted, ref } from 'vue';
import BoosterPicture from '#booster/components/BoosterPicture';
import BoosterImage from '#booster/components/BoosterImage';
import SvgChevronDown from '@/assets/svg/chevron-down.svg';
import { useBoosterFonts } from '#imports';
const { $getFont } = useBoosterFonts();
const ready = ref(false);
Expand Down
1 change: 0 additions & 1 deletion playground/components/modules/TextFontA.vue
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
</template>

<script setup>
import { useBoosterFonts } from '#imports';
const { $getFont } = useBoosterFonts();
defineProps({
headline: { type: String, default: 'Headline' },
Expand Down
1 change: 0 additions & 1 deletion playground/components/modules/TextFontB.vue
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
</template>

<script setup>
import { useBoosterFonts } from '#imports';
const { $getFont } = useBoosterFonts();
defineProps({
headline: { type: String, default: 'Headline' },
Expand Down
2 changes: 1 addition & 1 deletion playground/components/modules/VideoVimeo.vue
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
<script setup>
import BoosterVimeo from '#booster/components/BoosterVimeo';
import WeakHardwareOverlay from '@/components/WeakHardwareOverlay';
import { useBoosterFonts } from '#imports';
const { $getFont } = useBoosterFonts();
defineProps({
text: { type: String, default: null }
Expand Down
2 changes: 1 addition & 1 deletion playground/components/modules/VideoYoutube.vue
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<script setup>
import BoosterYoutube from '#booster/components/BoosterYoutube';
import WeakHardwareOverlay from '@/components/WeakHardwareOverlay';
import { useBoosterFonts } from '#imports';
const { $getFont } = useBoosterFonts();
defineProps({
text: { type: String, default: null }
Expand Down
2 changes: 0 additions & 2 deletions playground/layouts/default.vue
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@

<script setup>
import 'wicg-inert';
import { ref, defineAsyncComponent, computed } from 'vue';
import { useRoute, useHead } from '#app';
import boosterHydrate from '#booster/hydrate';
const InfoLayer = defineAsyncComponent(() => import('@/components/InfoLayer'));
Expand Down
2 changes: 0 additions & 2 deletions playground/pages/tests/booster-layer/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@
</template>

<script setup>
import { onMounted, ref } from 'vue';
import { definePageMeta } from '#imports';
import boosterHydrate from '#booster/hydrate';
import BoosterLayer from '#booster/components/BoosterLayer';
Expand Down
1 change: 0 additions & 1 deletion playground/pages/tests/booster-loader/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@

<script setup>
import boosterHydrate from '#booster/hydrate';
import { definePageMeta } from '#imports';
const Critical = boosterHydrate(() => import('./components/Critical'));
const Lazy = boosterHydrate(() => import('./components/Lazy'));
Expand Down
2 changes: 0 additions & 2 deletions playground/pages/tests/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@
</template>

<script setup>
import { definePageMeta } from '#imports';
definePageMeta({
layout: 'blank'
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@

<script setup>
import PreviewContainer from '@/components/PreviewContainer';
import { useBoosterFonts } from '#imports';
const { $getFont } = useBoosterFonts();
</script>

Expand Down
2 changes: 1 addition & 1 deletion playground/pages/tests/v-font-media/components/Lazy.vue
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@

<script setup>
import PreviewContainer from '@/components/PreviewContainer';
import { useBoosterFonts } from '#imports';
const { $getFont } = useBoosterFonts();
</script>

Expand Down
2 changes: 1 addition & 1 deletion playground/pages/tests/v-font/components/Critical.vue
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@

<script setup>
import PreviewContainer from '@/components/PreviewContainer';
import { useBoosterFonts } from '#imports';
const { $getFont } = useBoosterFonts();
</script>

Expand Down
2 changes: 1 addition & 1 deletion playground/pages/tests/v-font/components/Lazy.vue
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@

<script setup>
import PreviewContainer from '@/components/PreviewContainer';
import { useBoosterFonts } from '#imports';
const { $getFont } = useBoosterFonts();
</script>

Expand Down
1 change: 0 additions & 1 deletion playground/pages/tests/vimeo/components/Default.vue
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
</template>

<script setup>
import { computed } from 'vue';
import DefaultVimeo from '#booster/components/BoosterVimeo';
import PreviewContainer from '@/components/PreviewContainer';
Expand Down
3 changes: 0 additions & 3 deletions playground/pages/tests/weak-hardware-overlay/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,6 @@
</template>

<script setup>
import { ref, onMounted } from 'vue';
import { definePageMeta } from '#imports';
import BoosterLayer from '#booster/components/BoosterLayer';
import BoosterWeakHardwareOverlay from '#booster/components/WeakHardwareOverlay';
Expand Down
2 changes: 0 additions & 2 deletions playground/pages/tests/youtube/components/Default.vue
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@
</template>

<script setup>
import { computed } from 'vue';
import DefaultYoutube from '#booster/components/BoosterYoutube';
import PreviewContainer from '@/components/PreviewContainer';
Expand Down
3 changes: 0 additions & 3 deletions src/runtime/components/BoosterIframe.vue
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,6 @@
</template>

<script setup>
import { ref, watch } from 'vue';
import useBoosterComponentObserver from '#booster/composables/componentObserver';
const props = defineProps({
src: {
type: String,
Expand Down
2 changes: 0 additions & 2 deletions src/runtime/components/BoosterImage.vue
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
<script>
import { LazyHydrationWrapper } from 'vue3-lazy-hydration';
import { h } from 'vue';
import BoosterImage from '#booster/components/BoosterImage/Base';
import { useBoosterCritical } from '#imports';
export default {
inheritAttrs: false,
Expand Down
1 change: 0 additions & 1 deletion src/runtime/components/BoosterImage/utils/image.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { joinURL, parseURL, withBase, hasProtocol } from 'ufo';
import { useRequestURL } from '#app';

const SOURCE_FORMATS = ['avif', 'webp', 'png', 'jpg', 'gif'];
const FALLBACK_FORMAT = 'jpg';
Expand Down
2 changes: 0 additions & 2 deletions src/runtime/components/BoosterLayer.vue
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,6 @@
</template>

<script setup>
import { ref, onMounted } from 'vue';
import { useHead } from '#imports';
import { getStyleDescription } from '#booster/utils/description';
const isServer = ref(true);
Expand Down
2 changes: 0 additions & 2 deletions src/runtime/components/BoosterPicture.vue
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
<script>
import { LazyHydrationWrapper } from 'vue3-lazy-hydration';
import { h } from 'vue';
import BoosterPicture from '#booster/components/BoosterPicture/Base';
import { useBoosterCritical } from '#imports';
export default {
inheritAttrs: false,
Expand Down
3 changes: 0 additions & 3 deletions src/runtime/components/BoosterPicture/Source.vue
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,9 @@
</template>

<script>
import { computed } from 'vue';
import { getCrossorigin } from '#booster/utils';
import Source from '#booster/components/BoosterImage/classes/Source';
import { useImage, useNuxtApp, useHead } from '#imports';
const types = new Map([['jpg', 'jpeg']]);
export default {
Expand Down
1 change: 0 additions & 1 deletion src/runtime/components/BoosterVimeo.vue
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@
</template>

<script setup>
import { defineOptions } from 'vue';
import BaseVimeo from '#booster/components/BoosterVimeo/Base';
defineOptions({
Expand Down
3 changes: 0 additions & 3 deletions src/runtime/components/BoosterVimeo/Base.vue
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,12 @@
</template>

<script>
import { markRaw, ref, computed } from 'vue';
import DefaultButton from '../Button';
import { load, ready } from './utils/loader';
import Vimeo from './classes/Vimeo';
import { isTouchSupported } from '#booster/utils/browser';
import BoosterPicture from '#booster/components/BoosterPicture';
import { useHead } from '#imports';
const vimeo = new Vimeo();
export default {
Expand Down
1 change: 0 additions & 1 deletion src/runtime/components/BoosterYoutube.vue
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@
</template>

<script setup>
import { defineOptions } from 'vue';
import BaseYoutube from '#booster/components/BoosterYoutube/Base';
defineOptions({
Expand Down
3 changes: 0 additions & 3 deletions src/runtime/components/BoosterYoutube/Base.vue
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,12 @@
</template>

<script>
import { ref, markRaw, computed } from 'vue';
import DefaultButton from '../Button';
import { load } from './utils/loader';
import Youtube from './classes/Youtube';
import { isTouchSupported } from '#booster/utils/browser';
import BoosterPicture from '#booster/components/BoosterPicture';
import { useHead } from '#imports';
const youtube = new Youtube();
export default {
Expand Down
2 changes: 0 additions & 2 deletions src/runtime/components/Button.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@
</template>

<script setup>
import { defineOptions } from 'vue';
defineOptions({
inheritAttrs: false
});
Expand Down
1 change: 0 additions & 1 deletion src/runtime/components/WeakHardwareOverlay.vue
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
</template>

<script setup>
import { ref, onMounted } from 'vue';
const isServer = ref(true);
onMounted(() => (isServer.value = false));
Expand Down
2 changes: 0 additions & 2 deletions src/runtime/composables/componentObserver.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
import { onMounted, ref } from 'vue';
import { getElementObserver } from '#booster/classes/intersection';
import { useBoosterCritical } from '#imports';

export default function (options) {
const el = ref(null);
Expand Down
2 changes: 0 additions & 2 deletions src/runtime/composables/config.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import { useRuntimeConfig } from '#app';

export default function () {
const { booster: runtimeConfig } = useRuntimeConfig().public;
return runtimeConfig;
Expand Down
2 changes: 0 additions & 2 deletions src/runtime/composables/critical.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import { computed, ref, inject, provide, useAttrs } from 'vue';

const criticalContextKey = Symbol('criticalContext');

export default function ({ critical } = {}) {
Expand Down
3 changes: 0 additions & 3 deletions src/runtime/composables/fonts.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
import { computed, reactive } from 'vue';
import { useHead, useBoosterCritical, useBoosterConfig } from '#imports';
import { useNuxtApp } from '#app';
import FontCollection from '#booster/classes/FontCollection';

export default function (context) {
Expand Down
2 changes: 0 additions & 2 deletions src/runtime/hydrate.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
import { hydrateWhenVisible } from 'vue3-lazy-hydration';
import { defineAsyncComponent } from 'vue';
import { useRuntimeConfig } from '#imports';

const isDev = process.env.NODE_ENV === 'development';

Expand Down

0 comments on commit 297edf1

Please sign in to comment.