#Deploying a Meteor app to Digital Ocean
This file contains 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
// Using axios and fast-xml-parser you can retrieve the data received as xml and converted to json object. | |
import axios from 'axios'; | |
var fastXmlParser = require('fast-xml-parser'); | |
let jsonObj = {}; | |
axios.get('https://virgool.io/feed/@jEbrahimi') | |
.then(xml => xml.data) | |
.then(xmlText => { | |
if (fastXmlParser.validate(xmlText)) { |
This file contains 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
import React, { Component } from 'react' | |
import { BrowserRouter as Router, Route, Link, Match, Redirect, Switch } from 'react-router-dom' | |
import OverviewPage from './page/OverviewPage' | |
import AccountPage from './page/AccountPage' | |
/* | |
Layouts, inline define here for demo purpose | |
you may want to define in another file instead | |
*/ |
This file contains 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
/* | |
* To change this license header, choose License Headers in Project Properties. | |
* To change this template file, choose Tools | Templates | |
* and open the template in the editor. | |
*/ | |
package com.phil.wrapper; | |
import java.util.logging.Level; | |
import java.util.logging.Logger; | |
import org.jpos.iso.ISOException; |
This file contains 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 ParentComponent extends Component { | |
constructor() { | |
super(); | |
this.state = { | |
data : [ | |
{id : 1, date : "2014-04-18", total : 121.0, status : "Shipped", name : "A", points: 5, percent : 50}, | |
{id : 2, date : "2014-04-21", total : 121.0, status : "Not Shipped", name : "B", points: 10, percent: 60}, | |
{id : 3, date : "2014-08-09", total : 121.0, status : "Not Shipped", name : "C", points: 15, percent: 70}, | |
{id : 4, date : "2014-04-24", total : 121.0, status : "Shipped", name : "D", points: 20, percent : 80}, |
Sometimes you want to have a subdirectory on the master
branch be the root directory of a repository’s gh-pages
branch. This is useful for things like sites developed with Yeoman, or if you have a Jekyll site contained in the master
branch alongside the rest of your code.
For the sake of this example, let’s pretend the subfolder containing your site is named dist
.
Remove the dist
directory from the project’s .gitignore
file (it’s ignored by default by Yeoman).
This file contains 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
package com.code4startups.your.package.name; | |
import java.text.SimpleDateFormat; | |
import java.util.Date; | |
public class Config { | |
public static Date getDateFromStringDate(String dateInString) throws ParseException { | |
Log.e("dd", dateInString); | |
SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSZ"); |
This file contains 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
# Xcode | |
# | |
# gitignore contributors: remember to update Global/Xcode.gitignore, Objective-C.gitignore & Swift.gitignore | |
## Build generated | |
build/ | |
DerivedData/ | |
## Various settings | |
*.pbxuser |
This file contains 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Hello World!</title> | |
</head> | |
<body> | |
<h1>Hello World!</h1> | |
We are using node <script>document.write(process.versions.node)</script>, | |
Chrome <script>document.write(process.versions.chrome)</script>, |
This file contains 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 Car { | |
constructor(number_of_wheels, number_of_doors) { | |
this.number_of_wheels = number_of_wheels; | |
this.number_of_doors = number_of_doors; | |
} | |
getCarInfo() { | |
return this.number_of_wheels + ' wheels, ' + this.number_of_doors + ' doors.'; | |
} | |
} |
NewerOlder