Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

js regex

// get "bucket1337" from https://bucket1337.appspot.com.storage.googleapis.com/staging/blender_input/162480.glb"

//define string
let string = "https://bucket1337.appspot.com.storage.googleapis.com/staging/blender_input/162480.glb"

//define regexp
let bucketRegex = new RegExp(`(?<=https://).*(?=.app)`, 'gm')

// execute regexp
let result = string.match(bucketRegex)[0]
Source by eloquentjavascript.net #
 
PREVIOUS NEXT
Tagged: #js #regex
ADD COMMENT
Topic
Name
3+1 =