Using Add-ons & Dependencies
Once you have successfully installed a package into your project using the Dependencies Browser, you can start using it in your project.
Adding Add-ons to a zcomponent
Additional Mattercraft features can be enabled as a Component or Behavior Action.
Managing versions
You might want to use a specific version of a package to access certain features. You can manage your dependency versions seamlessly with the Dependencies Browser.
Never modify the three.js package version, as this can cause project issues. Mattercraft will automatically update this for you when a new version is supported.
Follow these instructions to do so:
- Open the Dependencies Browser and find the add-on you want to install
- Left click on the arrow icon next to the Install button and select a specific version
You can also edit the project's
package.json
file, as you might with other Node.js solutions.
Updating packages
At times, it might be required for you to update certain packages to the latest release. You can conveniently update your dependencies from the Add-ons and Dependencies panel, or via the Dependencies Browser:
From the Add-ons and Dependencies panel
- Click on the Add-ons and Dependencies panel
- Right click (or left click on the three dots when hovered) on the dependency you wish to modify
- Click on the Update option
From the Dependencies Browser
- Open the Dependencies Browser and click on the Installed tab
- Click on the dependency you wish to modify to open the information dialog
- Click on the Update to latest major version option
Removing packages
There may be situations whereby you no longer require a specific package in your project. In such cases, you can use the Add-ons & Dependencies panel or the Dependencies Browser to easily remove those packages.
From the Add-ons and Dependencies panel
- Click on the Add-ons and Dependencies panel
- Right click (or left click on the three dots when hovered) on the dependency you wish to modify
- Click on the Delete option
From the Dependencies Browser
- Open the Dependencies Browser and click on the Installed tab
- Locate the package you want to remove and click on it to open the information dialog
- Click on Remove Dependency to instantly remove the package from your project
Please note that removing a package will also remove all of the package dependencies that are not required by any other packages in your project. Always make sure to check whether the package is not being used elsewhere in your project before uninstalling it.