Skip to content

🐛 [Bug Cli V4]: Unable to load compiler-options as .ts file #307

@leanne-starling

Description

@leanne-starling

Package

storyblok (CLI)

Bug Description

When trying to use a compiler-options.ts file when generating types the command is throwing as error.

Steps to Reproduce

  1. Create a compiler options file called compiler-options.ts in root.
  2. Run generate types like so storyblok types generate --space [spaceId] --compiler-options ./compiler-options.ts

Expected Behavior

Types should be generated and compiler options should be applied

Actual Behavior

An error is thrown Unknown file extension ".ts" for [path]/compiler-options.ts

Environment

System:
    OS: macOS 15.6.1
    CPU: (14) arm64 Apple M4 Max
    Memory: 1.26 GB / 36.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 22.14.0 - ~/.volta/tools/image/node/22.14.0/bin/node
    npm: 10.9.0 - ~/.volta/tools/image/npm/10.9.0/bin/npm
  Browsers:
    Chrome: 140.0.7339.133
    Safari: 18.6
  npmPackages:
    @storyblok/react: ^5.0.0 => 5.0.0 
    next: ^15.5.2 => 15.5.2 
    react: ^19.1.0 => 19.1.0 
    storyblok: ^4.6.1 => 4.6.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions