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 SampleListItem extends StatelessWidget { | |
/// 方向 | |
final Axis direction; | |
/// 宽度 | |
final double width; |
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/rendering.dart'; | |
import 'dart:math' as math; | |
class SlidingCardsView extends StatefulWidget { | |
@override | |
_SlidingCardsViewState createState() => _SlidingCardsViewState(); | |
} | |
class _SlidingCardsViewState extends State<SlidingCardsView> { |
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
#create new laravel project | |
function nlp() { | |
DIR="$HOME/projects" | |
if [ -d "$DIR/$1" ]; then | |
echo "Directory $DIR/$1 exists already." | |
return 1 | |
fi |
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
org.gradle.jvmargs=-Xmx1536M | |
android.enableR8=true | |
android.useAndroidX=true | |
android.enableJetifier=true | |
android.enableUnitTestBinaryResources=true |
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
lintOptions { | |
disable 'InvalidPackage' | |
} | |
aaptOptions { | |
cruncherEnabled = false | |
} | |
defaultConfig { | |
applicationId "com.jodeveloper.missing" |
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
const rand=()=>Math.random(0).toString(36).substr(2); | |
const token=(length)=>(rand()+rand()+rand()+rand()).substr(0,length); | |
console.log(token(56)); | |
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
/** | |
* Bootstrap any application services. | |
* | |
* @return void | |
*/ | |
public function boot() | |
{ | |
Component::macro('notify', function ($message, $title = '', $type = 'success') { | |
$this->dispatchBrowserEvent('notify', ['message' => $message, 'title' => $title, 'type' => $type]); | |
}); |
OlderNewer