Skip to content

Commit 24c9405

Browse files
authored
chore: bump TS to 5.9 and typecheck docs (vitejs#20582)
1 parent 0a6048a commit 24c9405

File tree

21 files changed

+258
-169
lines changed

21 files changed

+258
-169
lines changed
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
interface Window {
2+
__VITE_BANNER_ID__: string
3+
}

docs/.vitepress/theme/components/SponsorBanner.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<script setup>
1+
<script setup lang="ts">
22
/**
33
* Adding a new banner:
44
* 1. uncomment the banner slot in ../index.ts
@@ -15,7 +15,7 @@ const open = ref(true)
1515
function dismiss() {
1616
open.value = false
1717
document.documentElement.classList.add('banner-dismissed')
18-
localStorage.setItem(`vite-docs-banner-${__VITE_BANNER_ID__}`, 'true')
18+
localStorage.setItem(`vite-docs-banner-${window.__VITE_BANNER_ID__}`, 'true')
1919
}
2020
</script>
2121

docs/.vitepress/theme/components/landing/1. hero-section/HeroDiagram.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
<script setup lang="ts">
22
import { gsap } from 'gsap'
33
import { MotionPathPlugin } from 'gsap/dist/MotionPathPlugin'
4-
import { onMounted, onUnmounted, Ref, ref } from 'vue'
4+
import { onMounted, onUnmounted, type Ref, ref } from 'vue'
55
import SvgInputs from './svg-elements/SvgInputs.vue'
66
import SvgOutputs from './svg-elements/SvgOutputs.vue'
77
import SvgBlueIndicator from './svg-elements/SvgBlueIndicator.vue'
88
import SvgPinkIndicator from './svg-elements/SvgPinkIndicator.vue'
99
import { ScrollTrigger } from 'gsap/dist/ScrollTrigger'
10-
import { SvgNodeProps } from '../common/SvgNode.vue'
10+
import type { SvgNodeProps } from '../common/SvgNode.vue'
1111
1212
gsap.registerPlugin(MotionPathPlugin)
1313

docs/.vitepress/theme/components/landing/1. hero-section/svg-elements/SvgInputs.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<script setup lang="ts">
2-
import SvgNode, { SvgNodeProps } from '../../common/SvgNode.vue'
3-
import { Ref } from 'vue'
2+
import SvgNode, { type SvgNodeProps } from '../../common/SvgNode.vue'
3+
import type { Ref } from 'vue'
44
55
defineProps({
66
inputLines: {

docs/.vitepress/theme/components/landing/1. hero-section/svg-elements/SvgOutputs.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<script setup lang="ts">
2-
import SvgNode, { SvgNodeProps } from '../../common/SvgNode.vue'
3-
import { Ref } from 'vue'
2+
import SvgNode, { type SvgNodeProps } from '../../common/SvgNode.vue'
3+
import type { Ref } from 'vue'
44
55
defineProps({
66
outputLines: {

docs/.vitepress/theme/components/landing/2. feature-section/FeatureCI.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<script setup lang="ts">
2-
import { Ref, ref } from 'vue'
2+
import { type Ref, ref } from 'vue'
33
import SvgNode from '../common/SvgNode.vue'
44
import { gsap } from 'gsap'
55
import { useSlideIn } from '../../../composables/useSlideIn'

docs/.vitepress/theme/components/landing/2. feature-section/FeatureOptimizedBuild.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<script setup lang="ts">
22
import SvgNode from '../common/SvgNode.vue'
3-
import { ref, Ref } from 'vue'
3+
import { ref, type Ref } from 'vue'
44
import { gsap } from 'gsap'
55
import { useSlideIn } from '../../../composables/useSlideIn'
66
import { useCardAnimation } from '../../../composables/useCardAnimation'
@@ -29,7 +29,7 @@ const { startAnimation } = useCardAnimation(
2929
const timeline = gsap.timeline()
3030
3131
// Animate in each node
32-
nodes.forEach((node, i) => {
32+
nodes.forEach((node) => {
3333
let subTimeline = gsap.timeline()
3434
subTimeline.call(() => {
3535
node.visible.value = true

docs/.vitepress/theme/components/landing/2. feature-section/FeatureSection.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<script setup lang="ts">
22
import SvgNode from '../common/SvgNode.vue'
3-
import { onMounted, onUnmounted, Ref, ref } from 'vue'
3+
import { onMounted, onUnmounted, type Ref, ref } from 'vue'
44
import { gsap } from 'gsap'
55
66
const props = defineProps({

docs/.vitepress/theme/components/landing/3. frameworks-section/FrameworkCard.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<script setup lang="ts">
2-
import { Ref, ref } from 'vue'
2+
import { type Ref, ref } from 'vue'
33
44
/**
55
* A single framework or tool to display in the frameworks section.

docs/.vitepress/theme/components/landing/3. frameworks-section/FrameworksSection.vue

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,13 @@
11
<script setup lang="ts">
2-
import { computed, ComputedRef, onMounted, onUnmounted, Ref, ref } from 'vue'
3-
import FrameworkCard, { Framework } from './FrameworkCard.vue'
2+
import {
3+
computed,
4+
type ComputedRef,
5+
onMounted,
6+
onUnmounted,
7+
type Ref,
8+
ref,
9+
} from 'vue'
10+
import FrameworkCard, { type Framework } from './FrameworkCard.vue'
411
import { gsap } from 'gsap'
512
import { ScrollTrigger } from 'gsap/dist/ScrollTrigger'
613

0 commit comments

Comments
 (0)