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 html_to_json | |
def get_recursively(search_dict, field): | |
""" | |
Takes a dict with nested lists and dicts, | |
and searches all dicts for a key of the field | |
provided. | |
""" | |
fields_found = [] |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>method</key> | |
<string>app-store</string> | |
<key>teamID</key> | |
<string>T1W23Z4N56</string> | |
<key>teamName</key> | |
<string>POCKET SYSTEMS</string> |
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
name: CD User-Prod-Lane | |
# Controls when the action will run. Triggers the workflow on push or pull request | |
# events but only for the master branch. | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
build: |
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
/** | |
* First we will load all of this project's JavaScript dependencies which | |
* includes Vue and other libraries. It is a great starting point when | |
* building robust, powerful web applications using Vue and Laravel. | |
*/ | |
require('./bootstrap'); | |
window.Vue = require('vue').default; | |
const Vue = window.Vue; |
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 'package:flutter/material.dart'; | |
class ResponsiveView extends StatelessWidget { | |
final Widget mobile; | |
final Widget tablet; | |
final Widget desktop; | |
const ResponsiveView({ | |
Key? key, | |
required this.mobile, | |
required this.tablet, |
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 'package:flutter/material.dart'; | |
import 'package:flutter/widgets.dart'; | |
class ListPage extends StatelessWidget{ | |
@override | |
Widget build(_) => ListView.builder( | |
itemCount: 2, | |
itemBuilder: (_,itemPosition)=>_ItemView(index: itemPosition) | |
); |
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 'package:http/http.dart' as http; | |
class Api{ | |
static final String BASE_URL = "http://yourserver.com"; | |
static final String API_KEY = "YOUR_KEY"; | |
static String fcmTOKEN = "YOUR_TOKEN"; | |
Future<http.Response> getRequest(String endPoint){ | |
return http.get(BASE_URL+"/"+endPoint, headers: { | |
"apikey": API_KEY |
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
public class MyThreadsApp { | |
public static void main (String [] args) | |
{ | |
Thread currentThread = Thread.currentThread(); | |
System.out.println(currentThread); | |
MyThread mt1 = new MyThread (); | |
mt1.setName("MyThread1"); |
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 android.view.LayoutInflater; | |
import android.view.View; | |
import android.view.ViewGroup; | |
import androidx.annotation.NonNull; | |
import androidx.recyclerview.widget.RecyclerView; | |
import java.util.ArrayList; | |
import java.util.Map; |
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.ishaquehassan.recyclerviewgeneraladapter | |
import android.support.v7.widget.RecyclerView | |
import android.view.LayoutInflater | |
import android.view.View | |
import android.view.ViewGroup | |
class RecyclerGeneralTypeAdapter<T>(val data:ArrayList<T>, private val layoutFiles:Map<Int,Int>, val onGetViewType:(Int, T)->Int, val onBindItem:(itemData:T, viewHolder:RecyclerGeneralTypeAdapter<T>.RecyclerGeneralViewHolder)->Unit) : RecyclerView.Adapter<RecyclerGeneralTypeAdapter<T>.RecyclerGeneralViewHolder>(){ | |
constructor(data:ArrayList<T>,layoutFile: Int,onBindItem:(T,RecyclerGeneralTypeAdapter<T>.RecyclerGeneralViewHolder)->Unit):this(data, mapOf(-10 to layoutFile),{_,_->-10},onBindItem) |
NewerOlder