Urgent.News

What's breaking now, across thousands of outlets.

Editions

Tech

Your feature-usage scanner doesn't know Vue, Svelte, or Astro exist. Here's how we fixed that without touching its core.

If a static analyzer only walks .ts / .tsx / .js / .jsx , every other file type isn't scanned badly - it's not scanned at all. A .vue component, a .svelte widget, an .astro page: none of them exist to the tool. Not "low confidence." Not "partial support." Invisible, the same way an empty search result looks identical whether there's genuinely nothing to find or the search just never looked in the…

The static analyzer tool used by Eventra didn't recognize Vue, Svelte, or Astro files, treating them as invisible and ignoring them during scans. This gap became apparent when teams working on multi-framework stacks had Vue admin panels, Svelte checkout widgets, and Astro sites, but the tool would give clean scans without acknowledging it hadn't scanned those frameworks.

The issue was resolved without modifying the core analysis engine of the CLI. Each framework had a separate plugin that translated the framework files into virtual TypeScript modules, allowing the core engine to process them without knowing they originated from a different framework. Vue files were transformed using @vue/compiler-sfc, Svelte files with svelte/compiler in legacy-AST mode, and Astro files with @astrojs/compiler.

This approach ensured that the core engine, built on the TypeScript compiler API, remained framework-agnostic while still accurately identifying tracked features across all frameworks.

Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.

Read the original at dev.to →

More in Tech

More from Friday 21 August →