easy-api.ts
Version:
A powerful library to create your own API with ease.
1 lines • 801 B
JavaScript
Object.defineProperty(exports,"__esModule",{value:!0});let APIFunction_1=require("../../classes/structures/APIFunction"),Util_1=require("../../classes/internal/Util");class StringStartsWith extends APIFunction_1.APIFunction{name="$stringStartsWith";description="Returns whether the given text starts with the provided word.";parameters=[{name:"Text",description:"The text to work with.",type:APIFunction_1.ParamType.String,required:!0,rest:!1,defaultValue:null},{name:"Word",description:"The word to be matched.",type:APIFunction_1.ParamType.String,required:!0,rest:!1,defaultValue:null}];usage="$stringStartsWith[text;word]";returns=APIFunction_1.ParamType.Boolean;aliases=["$startsWith"];compile=!0;async run(t,[e,r]){return Util_1.Util.stringBool(e.startsWith(r))}}exports.default=StringStartsWith;