Written with StackEdit.
Header 1
=======
Header 2
Written with StackEdit.
Header 1
=======
Header 2
import React from 'react'; | |
import ImageUploader from 'react-images-upload'; | |
import axios from 'axios'; | |
import imageDemo from './imagenes/demo.png'; | |
export default class App extends React.Component{ | |
constructor(props) { |
function onlyUnique(value, index, self) { | |
return self.indexOf(value) === index; | |
} | |
// usage example: | |
var a = ['a', 1, 'a', 2, '1']; | |
var unique = a.filter( onlyUnique ); // returns ['a', 1, 2, '1'] |
function money (n,c, d, t){ | |
var n = n, | |
c = isNaN(c = Math.abs(c)) ? 2 : c, | |
d = d == undefined ? "." : d, | |
t = t == undefined ? "," : t, | |
s = n < 0 ? "-" : "", | |
i = parseInt(n = Math.abs(+n || 0).toFixed(c)) + "", | |
j = (j = i.length) > 3 ? j % 3 : 0; | |
return s + (j ? i.substr(0, j) + t : "") + i.substr(j).replace(/(\d{3})(?=\d)/g, "$1" + t) + (c ? d + Math.abs(n - i).toFixed(c).slice(2) : ""); | |
}; |
{"switch":"si"} |
[{ | |
"arg": "valor1", | |
"argumento": "valor 2", | |
"imagen": "https://androidayuda.com/app/uploads-androidayuda.com/2019/07/android.jpg" | |
}, | |
{ | |
"arg": "valor 3", | |
"argumento": "valor 4", | |
"imagen": "https://www.muycomputer.com/wp-content/uploads/2020/01/android.jpg" | |
}, |
var addrUrl = "http://maps.googleapis.com/maps/api/geocode/json?sensor=true&latlng="+e.coords.latitude+","+e.coords.longitude; | |
var addrReq = Titanium.Network.createHTTPClient(); | |
addrReq.open("GET",addrUrl); | |
addrReq.send(null); | |
addrReq.onload = function() | |
{ |
var Cloud = require('ti.cloud'); | |
var currentSessionMode = Ti.Media.audioSessionCategory; | |
Ti.Media.audioSessionCategory = Ti.Media.AUDIO_SESSION_CATEGORY_PLAY_AND_RECORD; | |
var record = false; | |
var file; | |
var idSound; | |
/*** | |
* Appcelerator Titanium example of custom confirm dialog for TableView's delete events. | |
* Asks to confirm/cancel a delete operation. On cancel restores the deleted row in | |
* its former position in the table data. | |
* | |
* @Copyleft 2013 Patrick De Marta | |
* @License GNU GPL | |
*/ |
----------------------------------------------------------------------------------------- | |
-- | |
-- main.lua | |
-- | |
----------------------------------------------------------------------------------------- | |
-- Your code here | |
local physics = require('physics') | |
physics.start() |