Skip to content

Instantly share code, notes, and snippets.

View tosinonikute's full-sized avatar
🏠
Working from home

Tosin Onikute tosinonikute

🏠
Working from home
View GitHub Profile
version: 2.1
jobs:
build:
docker:
- image: circleci/python:3.8
steps:
- checkout
name: Install and Configure AWS CLI
on: [push]
jobs:
install_configure_aws_cli:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v2
// 1 . WebViewContainer is a NSViewRepresentable SwiftUI view that wraps a WKWebView and loads a URL.
// 2. The ContentView contains the WebViewContainer and a title.
// 3. The WebViewApp is the main entry point for the app.
import SwiftUI
import WebKit
struct WebViewContainer: NSViewRepresentable {
let urlString: String
import UIKit
protocol TableViewCellDelegate {
func buttonTapped(_ cell: SampleTableViewCell)
}
class SampleTableViewCell: UITableViewCell {
@IBOutlet weak var name: UILabel!
// Modules to control application life and create native browser window
const {app, BrowserWindow} = require('electron')
// Keep a global reference of the window object, if you don't, the window will
// be closed automatically when the JavaScript object is garbage collected.
let mainWindow
function createWindow () {
// Create the browser window.
mainWindow = new BrowserWindow({width: 800, height: 600})
Main Processes Renderer Processes
Main Processes Renderer Processes
Main Processes Renderer Processes
Main Processes Renderer Processes
Main Processes Renderer Processes
<!--
PHP
if(isset($_POST['question'])){
$question = $_POST['question'];
foreach($question as $q){
}
}
-->
public class Refs {
int value = 0;
// similar to :4 case in the c++ example
static void accept_reference(Example e) { // :1
e.value++; // will change the referenced object
e = null; // will only change the parameter
}
function extract_youtube_id($url){
$youtubeid = "";
if (preg_match('/youtube\.com\/watch\?v=([^\&\?\/]+)/', $url, $id)) {
$youtubeid = $id[1];
} else if (preg_match('/youtube\.com\/embed\/([^\&\?\/]+)/', $url, $id)) {
$youtubeid = $id[1];
} else if (preg_match('/youtube\.com\/v\/([^\&\?\/]+)/', $url, $id)) {
$youtubeid = $id[1];
APK splits allow developers to build multiple APKs for different screen sizes and ABIs. Enabling APK splits ensures that the minimum amount of files required to support a particular device are packaged into an APK.
The following snippet shows an example build.gradle with APK splits enabled.
```
apply plugin: 'com.android.application'
android {
// Specify that we want to split up the APK based on ABI
splits {