- Clear feature ownership
- Module usage predictibility (refactoring, maintainence, you know what's shared, what's not, prevents accidental regressions, avoids huge directories of not-actually-reusable modules, etc)
This file contains hidden or 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 val NETWORK_PAGE_SIZE = 500 | |
| private const val INITIAL_LOAD_SIZE = 1 | |
| class CryptoListPagingSource( | |
| private val service: APIService, | |
| private val mapper: CryptoListMapper | |
| ) : PagingSource<Int, CryptoItemResponse>() { | |
| override suspend fun load(params: LoadParams<Int>): LoadResult<Int, CryptoItemResponse> { | |
| // Start refresh at position 1 if undefined. |
This file contains hidden or 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
| <?php | |
| namespace App\Providers; | |
| use Illuminate\Support\ServiceProvider; | |
| class GoogleDriveServiceProvider extends ServiceProvider | |
| { | |
| /** | |
| * Bootstrap the application services. |
This file contains hidden or 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 sample.com.sample_app; | |
| import android.support.annotation.NonNull; | |
| public class FileUtils { | |
| @NonNull | |
| public static String generateName() { | |
| return Long.toString(System.currentTimeMillis()); | |
| } |
You can add your Charles Root Certificate to your root certificate trust store in Java, then all Java applications will trust the certificates that Charles issues. Note that you may need to do this each time you upgrade your Java installation.
In Charles go to the Help menu and choose "SSL Proxying > Save Charles Root Certificate".
Save the root certificate (as a .crt) to your desktop, or somewhere where you can easily access it in the next step.
Now find the cacerts file, it should be in your $JAVA_HOME/jre/lib/security/cacerts, where $JAVA_HOME is your java home directory for the JVM you’re using.
Then type (substituting for JAVAHOME and DESKTOP):
This file contains hidden or 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
| # the IP(s) on which your node server is running. I chose port 3000. | |
| upstream app_geoforce { | |
| server 127.0.0.1:3000; | |
| } | |
| upstream app_pcodes{ | |
| server 127.0.0.1:3001; | |
| } |
This file contains hidden or 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
| var nodes = document.getElementById("reaction_profile_browser").childNodes; | |
| var lists = []; | |
| nodes.forEach(function(element){lists.push(element.querySelector("div._5j0e a").textContent)}); | |
| lists.forEach(function(name){ | |
| if(name.toLocaleLowerCase().indexOf("linh")> -1) | |
| console.log(name) | |
| }) |
This file contains hidden or 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
| var email = "youremail"; | |
| var password = "yourpassword"; | |
| var BASE_URL = "https://api.facebook.com/restserver.php"; | |
| var API_SECRET = "62f8ce9f74b12f84c123cc23437a4a32"; | |
| var md5 = function(d){result = M(V(Y(X(d),8*d.length)));return result.toLowerCase()};function M(d){for(var _,m="0123456789ABCDEF",f="",r=0;r<d.length;r++)_=d.charCodeAt(r),f+=m.charAt(_>>>4&15)+m.charAt(15&_);return f}function X(d){for(var _=Array(d.length>>2),m=0;m<_.length;m++)_[m]=0;for(m=0;m<8*d.length;m+=8)_[m>>5]|=(255&d.charCodeAt(m/8))<<m%32;return _}function V(d){for(var _="",m=0;m<32*d.length;m+=8)_+=String.fromCharCode(d[m>>5]>>>m%32&255);return _}function Y(d,_){d[_>>5]|=128<<_%32,d[14+(_+64>>>9<<4)]=_;for(var m=1732584193,f=-271733879,r=-1732584194,i=271733878,n=0;n<d.length;n+=16){var h=m,t=f,g=r,e=i;f=md5_ii(f=md5_ii(f=md5_ii(f=md5_ii(f=md5_hh(f=md5_hh(f=md5_hh(f=md5_hh(f=md5_gg(f=md5_gg(f=md5_gg(f=md5_gg(f=md5_ff(f=md5_ff(f=md5_ff(f=md5_ff(f,r=md5_ff(r,i=md5_ff(i,m=md5_ff(m,f,r,i,d[n+0],7,-680876936),f,r,d[n+1],12,-389564586),m, |
NewerOlder