You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The documentation about importing from extensions explains how to import from flarum-tags extension. So I was hoping to be able to use the tagLabel function this way. But it turns out nothing is exported by this extension. Which is unfortunate when trying to follow the exemple.
Expect to be able to use some functions from the demonstrated flarum-tags extension
Find out after many tries that nothing is actually exported by this extension
Expected Behavior
The flarum-tags extension should export at least some of its functions. Not only to make fix the exemple in the docs but also to give more possibilities to extension developers.
As the tags extension is almost always installed, it may be interesting to extend its features. And giving access to function to allow displaying tags would be very useful.
Screenshots
No response
Environment
Flarum version: 1.6.2
Website URL: localhost
Webserver: PHP Built-in web server
Hosting environment: local machine
PHP version: 8.1.12
Browser: Mozilla Firefox 107.0.1
Output of php flarum info
Output of "php flarum info", run this in terminal in your Flarum directory.
Possible Solution
Add exports for at least tagLabel, tagsLabel and tagIcon to flarum-tags to make them accessible to extensions.
Additional Context
No response
The text was updated successfully, but these errors were encountered:
Thank you, this is working as expected! It seems the Webpack step is not needed with this method of import:
module.exports=require('flarum-webpack-config')({// Provide the extension IDs of all extensions from which your extension will be importing.// Do this for both full and optional dependencies.useExtensions: ['flarum-tags']});
Current Behavior
The documentation about importing from extensions explains how to import from
flarum-tags
extension. So I was hoping to be able to use thetagLabel
function this way. But it turns out nothing is exported by this extension. Which is unfortunate when trying to follow the exemple.This issue has already been reported on the forum but has not received any answer.
Steps to Reproduce
flarum-tags
extensionExpected Behavior
The
flarum-tags
extension should export at least some of its functions. Not only to make fix the exemple in the docs but also to give more possibilities to extension developers.As the tags extension is almost always installed, it may be interesting to extend its features. And giving access to function to allow displaying tags would be very useful.
Screenshots
No response
Environment
Output of
php flarum info
Possible Solution
Add exports for at least
tagLabel
,tagsLabel
andtagIcon
toflarum-tags
to make them accessible to extensions.Additional Context
No response
The text was updated successfully, but these errors were encountered: