Skip to main content

Script Library Configuration

OptionRequiredTypeDescription
bundleNobooleanWhether scripts should be bundled into their entry file, disregarding the source file structure.
If omitted, scripts are not bundled.
dependenciesYesDependenciesWhich other script libraries this library depends on.
directoriesYesDirectoriesDetermines the source, development and build directories for the script library.
entriesYesstring[]Array of file paths to be treated as script entries. At least one is required.
minifyNobooleanCompresses output script files, removing comments, whitespace and shortening names.
If omitted, scripts are not minified.
source_mapNobooleanImproves debugging by mapping outputted development files to their source files.
If omitted, sourcemaps are generated during development.
targetYes"stable"
"preview"
Whether this creation targets Minecraft (stable) or Minecraft Preview. Determines which type definitions for native script libraries are available and installed.
tree_shakeNobooleanWhether unused code and intermediate files are removed from the outputted files.
If omitted, tree shaking occurs.
typeYes"script_library"Defines this creation as a script library.

Directories

OptionRequiredTypeDescription
buildYesstringWhere will be built to for publishing with the minepicker build command.
developmentYesstringWhere will be built to during development with the minepicker dev command.
sourceYesstringWhere source files are located.

Dependencies

KeyValueDescription
<libraryName><versionRange>Where keys are library names and values are the required string version range.