This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Basic GET request using fetch API | |
async function GET() { | |
try{ | |
var url = "http://domain.com/route/api/endpoint"; | |
var get = await fetch(url); | |
var val = await get.text(); | |
console.log(val); | |
}catch(e){ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Shaders{ | |
static basic_vertex() { | |
return ` | |
void main() { | |
gl_Position = projectionMatrix * modelViewMatrix * vec4(position,1.0); | |
} | |
`; | |
} | |
static basic_fragment() { |
NewerOlder