{
test: /\.(js|jsx)$/,
exclude: /node_modules/,
use: ['babel-loader']
}
$.get('http://ip-api.com/json/', function(data) {
$('body').html(data);
});
fetch('http://ip-api.com/json/', {
method: 'GET',
headers: new Headers({
'Content-Type': 'text/plain',
'Access-Control-Allow-Origin': '*'
})
})
.then(resolve => {
return resolve.json()
})
.then(data => {
console.log(data)
})
const command = ffmpeg('desktop')
.duration(30)
.size('1920x1080')
.inputFPS(25)
.addInputOption('-f gdigrab')
.on('progress', e => {
console.log(e)
})
.on('end', () => {
console.log('Done!')
})
.on('error', err => {
console.error(err.message)
})
.save(path.resolve(__dirname, 'files', 'output.mpg'))
private void Form1_MouseDoubleClick(object sender, MouseEventArgs e)
{
Thread.Sleep(10000);
SendKeys.Send("{ENTER}");
SendKeys.Send("{ENTER}");
SendKeys.Send("{ENTER}");
SendKeys.Send("{ENTER}");
SendKeys.Send("{ENTER}");
SendKeys.Send("{ENTER}");
}
Failed to load https://ifyouhavemoneyforbitcoin.herokuapp.com/: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://localhost:3001' is therefore not allowed access.
axios({
method: 'post', //you can set what request you want to be
url: 'https://ifyouhavemoneyforbitcoin.herokuapp.com',
data: { time: Date.now() },
headers: {
'Content-Type': 'application/x-www-form-urlencoded'
}
})
.then(({ data: bitcoin }) => {
return bitcoin.cost
})
.then(bitcoin => {
this.setState({
data: addDataPoint(data, bitcoin, time)
});
})
.catch(err => {
console.error(err);
});
router.get('/subscribe', async (ctx, next) => {
console.log(`Clients: ${clients.length + 1}`);
const data = await new Promise((resolve, reject) => {
clients.push(resolve);
});
ctx.body = data;
});