Skip to content

Instantly share code, notes, and snippets.

View verdipratama's full-sized avatar
🧑‍💻
I have no idea how to code

Verdi Pratama verdipratama

🧑‍💻
I have no idea how to code
View GitHub Profile
@eveningkid
eveningkid / react-native-animated_twitter-profile.jsx
Last active March 7, 2024 23:57
React Native Animated: Twitter Profile Example
// Expo SDK41
// expo-blur: ~9.0.3
import React, { useRef } from 'react';
import {
Animated,
Image,
ImageBackground,
ScrollView,
StatusBar,
@RobertBrunhage
RobertBrunhage / Flutter_test_snippets.code-snippets
Created January 2, 2021 15:07
These snippets I have gotten from FilledStacks so make sure to follow him!
{
"Main Test Suite Setup": {
"prefix": "testm",
"body": [
"import 'package:flutter_test/flutter_test.dart';",
"",
"void main() {",
" group('${1:${TM_FILENAME_BASE/(.*)/${1:/pascalcase}/g}} -', (){",
"",
" });",
@graphicbeacon
graphicbeacon / main.dart
Created November 27, 2020 15:41
Shelf_router server example with CORS enabled
import 'package:shelf_router/shelf_router.dart';
import 'package:shelf/shelf.dart';
import 'package:shelf/shelf_io.dart' as io;
void start() async {
// Initiate server
const port = 8081;
final app = Router();
// CORS Settings
include: all_lint_rules.yaml
analyzer:
exclude:
- "**/*.g.dart"
- "**/*.freezed.dart"
# This is generated from the i18n vscode extension
- "**/i18n.dart"
strong-mode:
implicit-casts: false
implicit-dynamic: false
linter:
rules:
- always_declare_return_types
- always_put_control_body_on_new_line
- always_put_required_named_parameters_first
- always_require_non_null_named_parameters
- always_specify_types
- annotate_overrides
- avoid_annotating_with_dynamic
- avoid_as
@mohamed-samir907
mohamed-samir907 / local_notifications.dart
Created August 1, 2020 22:42
Flutter local notifications with alarm manager
import 'package:flutter_local_notifications/flutter_local_notifications.dart';
FlutterLocalNotificationsPlugin localNotificationsPlugin = FlutterLocalNotificationsPlugin();
void initNotifications () async {
var initializeAndroid = AndroidInitializationSettings('@mipmap/ic_launcher');
var initializeIOS = IOSInitializationSettings();
var initializationSettings = InitializationSettings(initializeAndroid, initializeIOS);
await localNotificationsPlugin.initialize(initializationSettings);
@maliouris
maliouris / beautifier.js
Last active January 21, 2022 03:29 — forked from fzldn/beautifier.js
VS Code Laravel Blade formatter using extension Beautify 1.5.0 by HookyQR with js-beautify hacks
...
Beautifier.prototype.beautify = function() {
...
var source_text = this._source_text;
// BEGIN
source_text = source_text.replace(/\{\{(--)?((?:(?!(--)?\}\}).)+)(--)?\}\}/g, function(m, ds, c, dh, de) {
@alexanderbazo
alexanderbazo / build.yml
Created December 6, 2019 16:07
Github Actions: Build and Release Android-APK
name: Minimal Android CI Workflow
on:
push:
branches:
- master
tags:
- 'v*'
jobs:
@verdipratama
verdipratama / .editorconfig
Created March 2, 2019 06:09
My editorconfig setup
# EditorConfig. Frontend. Default. Namics.
# @see: http://EditorConfig.org
# install a plugin to your editor: http://editorconfig.org/#download
# mark: not all plugins supports the same EditorConfig properties
# This is the top-most .editorconfig file (do not search in parent directories)
root = true
### All files
[*]
@wangruohui
wangruohui / Install NVIDIA Driver and CUDA.md
Last active April 23, 2024 02:03
Install NVIDIA Driver and CUDA on Ubuntu / CentOS / Fedora Linux OS