AlexLavoie42 / Nuxt-Mapbox

Elegant Mapbox integration with Nuxt
81 stars 11 forks source link

Feature Request: Add `setRTLTextPlugin` support to module options #59

Closed ielb closed 10 months ago

AlexLavoie42 commented 1 year ago

RTLTextPlugin will need to be added to module options, and set in the same way as the rest of the options in plugin.client.ts:

    const appConfig = useAppConfig() as ExtendedAppConfig
    //@ts-ignore
    mapboxgl.accessToken = appConfig._MAPBOX_CONFIG.accessToken;
    //@ts-ignore
    if (appConfig._MAPBOX_CONFIG.baseApiUrl) mapboxgl.baseApiUrl = appConfig._MAPBOX_CONFIG.baseApiUrl;
    //@ts-ignore
    if (appConfig._MAPBOX_CONFIG.workerUrl) mapboxgl.workerUrl = appConfig._MAPBOX_CONFIG.workerUrl;
    //@ts-ignore
    if (appConfig._MAPBOX_CONFIG.workerCount) mapboxgl.workerCount = appConfig._MAPBOX_CONFIG.workerCount;
    //@ts-ignore
    if (appConfig._MAPBOX_CONFIG.prewarm) mapboxgl.prewarm();

Some things to consider if anyone is interested in implementing:

AlexLavoie42 commented 10 months ago

Added in #73