Importing ContextId for BuilderContextInterface from @builder.io/sdk-qwik

Hi, I wrote this helper function:

import { createContextId, useContext } from "@builder.io/qwik";
import type { BuilderContextInterface } from "@builder.io/sdk-qwik/types/src/context/types";

const BuilderContextId = createContextId<BuilderContextInterface>("Builder");

export function useBuilderContext() : BuilderContextInterface {
  return useContext(BuilderContextId);
}

With this I can access the BuilderContext via QWIK useContext.
However, I could not find a way to import the ContextId from the SDK, so I had to recreate it with the same tag (“Builder”), which works, but is not very robust.

Is there a way to import this ID from the SDK?

Thanks,
Marton

Hi @maprohu Welcome to the Builder.io Forum!

Unfortunately, this forum channel is only intended for questions about the use of the Builder.io Visual Editor and its related plans and pricing.

However, Our Open source development team would love to help you take advantage of Qwik to boost your site performance scores further and provide more value to your implementation with Builder.

To reach out to the Qwik open source project teams, please head over to our Discord and join the discussion there.

You are also welcome to reach out for Partytown help by creating a discussion topic or Issue in the Github repo: https://github.com/BuilderIO/partytown/

I hope you find the information above helpful and please don’t hesitate to reach out to us if you need any further assistance.

Regards,