This is a snippet for uploading images using the html5 file input on the device. This will capture the image selected in base64 format, so it can be easly uploaded to a backend.
It should trigger something like this:
'use strict'; | |
const functions = require('firebase-functions'), | |
admin = require('firebase-admin'); | |
const token = functions.config().qvo.token; | |
admin.initializeApp(functions.config().firebase); | |
var fetch = require('node-fetch'); |
/* istanbul ignore file */ | |
// @ts-nocheck | |
import { createMuiTheme } from "@material-ui/core/styles"; | |
const theme = createMuiTheme({ | |
palette: { | |
primary: { | |
main: "rgba(2,51,101,1)", | |
dark: "rgba(17,43,69,1)", | |
light: "rgba(30,101,174,1)", |