Skip to content

[bug]: Registry item file ignores folders #6653

Open
@ivasilov

Description

Describe the bug

I'm trying to build a new registry and it's hard to predict where the file will be installed.
For example, using this file definition:

{
  "path": "src/registry/misc/lib/supabase/client.ts",
  "type": "registry:lib"
 }

The file is installed in <lib folder>/client.ts instead of <lib-folder>/acme/client.ts. I tried all variations, couldn't get it work. I want to avoid setting target and just let it use the lib defined folder.

In other files, the import is correctly changed during the installation from @/registry/misc/lib/supabase/client to @/<lib-folder>/supabase/client.

Affected component/components

Registry

How to reproduce

  1. Add this entry to a registry item
{
  "path": "src/registry/misc/lib/supabase/client.ts",
  "type": "registry:lib"
 }
  1. Set a custom lib folder in components.json in a test project.
  2. Install the component/block from a running registry
  3. The file should be <lib-folder>/acme/client.ts but it's in <lib-folder>/client.ts

Codesandbox/StackBlitz link

No response

Logs

System Info

[email protected], MacOS 15.2, Nodejs v20.11

Before submitting

  • I've made research efforts and searched the documentation
  • I've searched for existing issues

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions