npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

gaql-vscode

v0.1.2

Published

Language support for Google Ads Query Language (GAQL): validation, autocomplete, IntelliSense, and diagnostics

Downloads

2

Readme

Google Ads Query Language (GAQL) for VS Code

Language support for Google Ads Query Language (GAQL) with validation, autocomplete, IntelliSense, and diagnostics.

Features

✅ Real-time Validation

  • Validates GAQL queries in TypeScript/JavaScript template literals
  • Detects missing SELECT/FROM clauses
  • Validates resource names and field names
  • Provides detailed error messages with line/column information

💡 Intelligent Autocomplete

  • Context-aware suggestions for keywords, resources, fields, metrics, and segments
  • Filters suggestions based on the selected resource
  • Supports all Google Ads API versions (v19, v20, v21)

🔍 Rich IntelliSense

  • Hover information for fields and resources
  • Field type information and descriptions
  • Quick documentation access

🛠️ Code Actions

  • Quick fixes for common issues
  • Disable validation for specific lines or entire files
  • Suggestions for similar field names (typo correction)

🎯 Activation Control

  • Fine-grained control with comment directives:
    • // @gaql or // @gaql-enable - Enable for following queries
    • // @gaql-disable - Disable for following queries
    • // @gaql-disable-next-line - Disable for the next query only
  • Global activation mode setting

🌍 Multi-language Support

  • English
  • Japanese (日本語)
  • Automatically detects VS Code language settings

Installation

From VS Code Marketplace

  1. Open VS Code
  2. Go to Extensions (Ctrl+Shift+X / Cmd+Shift+X)
  3. Search for "Google Ads Query Language" or "gaql-vscode"
  4. Click Install

From VSIX File

  1. Download the .vsix file from Releases
  2. Open VS Code
  3. Open Command Palette (Ctrl+Shift+P / Cmd+Shift+P)
  4. Run Extensions: Install from VSIX...
  5. Select the downloaded VSIX file

Usage

The extension automatically activates for TypeScript and JavaScript files. Write GAQL queries in template literals:

// Enable GAQL validation for this query
// @gaql
const query = `
  SELECT
    campaign.id,
    campaign.name,
    metrics.impressions,
    metrics.clicks
  FROM campaign
  WHERE campaign.status = "ENABLED"
`;

Activation Modes

Always Mode (Default behavior: Active)

// Validation is active by default
const query = `SELECT campaign.id FROM campaign`;

// Disable for specific query
// @gaql-disable
const rawQuery = `This won't be validated`;

On-Demand Mode (Default behavior: Inactive)

// Validation is inactive by default
const ignored = `SELECT invalid syntax`;

// Enable for specific query
// @gaql
const validated = `SELECT campaign.id FROM campaign`;

Configuration

Access settings via: File > Preferences > Settings (or Code > Settings on macOS), then search for "gaql"

Available Settings

gaql.enabled

  • Type: boolean
  • Default: true
  • Description: Enable/disable GAQL validation and autocompletion

gaql.activationMode

  • Type: string ("always" | "onDemand")
  • Default: "onDemand"
  • Description: Default behavior when no comment directive is present
    • always: Active by default, can be disabled with @gaql-disable
    • onDemand: Inactive by default, can be enabled with @gaql or @gaql-enable

gaql.apiVersion

  • Type: string ("19" | "20" | "21")
  • Default: "21"
  • Description: Google Ads API version to use for schema and validation
    • 19: Supported until February 2026
    • 20: Supported until June 2026
    • 21: Supported until August 2026

gaql.language

  • Type: string ("auto" | "en" | "ja")
  • Default: "auto"
  • Description: Language for error messages and UI text
    • auto: Automatically detect from VS Code
    • en: English
    • ja: Japanese (日本語)

Related Packages

This extension is part of the GAQL Tools monorepo:

  • @gaql/core: Core validation, schema, and parser library
  • @gaql/cli: Command-line tool for validating GAQL queries in files
  • gaql-vscode (this extension): VS Code language support

Development

This extension is built with:

  • TypeScript 5.9
  • Vite 7.1 (for bundling)
  • Biome 2.2 (for linting/formatting)
  • @gaql/core (for validation logic)

Building from Source

# Clone the repository
git clone https://github.com/kage1020/google-ads-query-language.git
cd google-ads-query-language

# Install dependencies
pnpm install

# Build the extension
pnpm --filter gaql-vscode build

# Package the extension
pnpm --filter gaql-vscode package

Contributing

Contributions are welcome! Please see CONTRIBUTING.md for guidelines.

License

MIT License - see LICENSE for details.

Support

Changelog

See CHANGELOG.md for release history.