- A = [xA, yA] is a point on the 2D plane. Same for B, C, ...
- lengths are in any unit (ex: pixels)
- code snippets are in JavaScript
angleRad = angleDeg * Math.PI / 180;
| const templates = Object.create(null, { | |
| load: { | |
| value: async function(fileName) { | |
| const url = new URL(fileName, | |
| document.currentScript && document.currentScript.src || location.href) | |
| if (url in this) return this[url] | |
| // fetch and parse template as string | |
| let template = await fetch(url) | |
| template = await template.text() | |
| template = new DOMParser().parseFromString(template, 'text/html') |
| package main | |
| import ( | |
| "bufio" | |
| "flag" | |
| "fmt" | |
| "io" | |
| "os" | |
| "path/filepath" | |
| "regexp" |
| //Access the Spreadsheet - Declare globally | |
| var ssid = ScriptProperties.getProperty('ssid'); //Spreadsheet ID. Value has been stored as a property | |
| var ss = SpreadsheetApp.openById(ssid); //Opens the Spreadsheet using the stored property Spreadsheet ID | |
| //Create variables for known sheets and all sheets | |
| var iosSheet = getValueOfSheetByName("iOS"); //The iOS sheet | |
| var gasSheet = getValueOfSheetByName("GAS"); //The Google Apps Script sheet | |
| var allSheets = getValueOfAllSheets(); //All Sheet Values |
Here are the simple steps needed to create a deployment from your local GIT repository to a server based on this in-depth tutorial.
You are developing in a working-copy on your local machine, lets say on the master branch. Most of the time, people would push code to a remote server like github.com or gitlab.com and pull or export it to a production server. Or you use a service like deepl.io to act upon a Web-Hook that's triggered that service.
| // Exemplo de requisição GET | |
| var ajax = new XMLHttpRequest(); | |
| // Seta tipo de requisição e URL com os parâmetros | |
| ajax.open("GET", "minha-url-api.com/?name=Henry&lastname=Ford", true); | |
| // Envia a requisição | |
| ajax.send(); | |
| // Cria um evento para receber o retorno. |
| var viewer = new Cesium.Viewer('cesiumContainer', { | |
| targetFrameRate: 60, | |
| homeButton: false, | |
| sceneModePicker: false, | |
| navigationHelpButton: false, | |
| baseLayerPicker: false, | |
| clock: new Cesium.Clock({ | |
| startTime: Cesium.JulianDate.fromIso8601('1880-01-01'), | |
| currentTime: Cesium.JulianDate.fromIso8601('1880-01-01'), | |
| stopTime: Cesium.JulianDate.fromIso8601("2013-12-01"), |
| var viewer = new Cesium.Viewer('cesiumContainer', { | |
| infoBox : false, | |
| selectionIndicator : false | |
| }); | |
| var entity = viewer.entities.add({ | |
| position : Cesium.Cartesian3.fromDegrees(-123, 44, 10), | |
| model : { | |
| uri : '../../../Specs/Data/Models/Box/CesiumBoxTest.gltf', | |
| minimumPixelSize : 128 |
| # You don't need Fog in Ruby or some other library to upload to S3 -- shell works perfectly fine | |
| # This is how I upload my new Sol Trader builds (http://soltrader.net) | |
| # Based on a modified script from here: http://tmont.com/blargh/2014/1/uploading-to-s3-in-bash | |
| S3KEY="my aws key" | |
| S3SECRET="my aws secret" # pass these in | |
| function putS3 | |
| { | |
| path=$1 |