Dev Tipshttps://dev-tips.com/Tips, tricks, techniques, tutorials, and tidbits for software developersen-USTue, 05 Jan 2021 23:06:09 +0000© Dev Tips 2021Capture network traffic for reverse engineering APIs of iOS appshttps://dev-tips.com/tools/capture-network-traffic-for-reverse-engineering-apis-of-ios-appshttps://dev-tips.com/tools/capture-network-traffic-for-reverse-engineering-apis-of-ios-appsHow to set up »Charles« for iOS to capture and inspect network requests and responses (including meta data, headers, and bodies) directly on your iOS device.Sun, 15 Mar 2020 15:18:13 +0000Overlapping bottom navigation bar despite 100vh in iOS Safarihttps://dev-tips.com/css/overlapping-bottom-navigation-bar-despite-100vh-in-ios-safarihttps://dev-tips.com/css/overlapping-bottom-navigation-bar-despite-100vh-in-ios-safari»100vh« may not behave as expected for some mobile browsers and the bottom of your content will be partially hidden behind the browser’s bottom bar (i.e. below the »fold«).Sun, 09 Feb 2020 14:54:50 +0000Conditional overriding of Git configurations for single and multiple repositorieshttps://dev-tips.com/git/conditional-overriding-of-git-configurationshttps://dev-tips.com/git/conditional-overriding-of-git-configurationsHow to change configuration properties like your Git user when working in different contexts for no more accidental commits with the wrong name or email address.Tue, 04 Feb 2020 22:59:03 +0000Node.js package names are case-sensitivehttps://dev-tips.com/nodejs/nodejs-package-names-are-case-sensitivehttps://dev-tips.com/nodejs/nodejs-package-names-are-case-sensitiveA buddy of mine just blundered into this trap/pitfall while including jQuery into a project. Both jQuery and jquery do exist in npm’s registry. While the latter is the one he was looking for, he snapped the former (due to »jQuery« being the official notation). This caused a lot of (reasonable) confu…Mon, 03 Feb 2020 19:21:52 +0000Announcing Dev Tipshttps://dev-tips.com/announcements/announcing-dev-tipshttps://dev-tips.com/announcements/announcing-dev-tipsToday, I’m happy to announce that this site is rebranding from »Frontend-Development.com« to »Dev Tips« and expanding its niche and proposition.Sun, 02 Feb 2020 13:44:39 +0000Update existing SSH private keyhttps://dev-tips.com/tools/update-existing-ssh-private-keyhttps://dev-tips.com/tools/update-existing-ssh-private-keyIf your private key is still in an old or unsecure format (e.g. without a passphrase), you can update it using the following command.Mon, 20 Jan 2020 22:53:52 +0000Micro-frontends: porting the micro-service approach into the frontendhttps://dev-tips.com/frontend/micro-frontends-porting-the-micro-service-approach-into-the-frontendhttps://dev-tips.com/frontend/micro-frontends-porting-the-micro-service-approach-into-the-frontendThe functionality of Web applications is growing steadily, and collaborative work of multiple teams on a common codebase may become kind of impractical quite fast. Collaboration could be efficient though, if the teams were able to work scalable and largely autonomous of each other while still keepin…Sat, 23 Feb 2019 11:39:14 +0000Difference between »throttling« and »debouncing« a JavaScript functionhttps://dev-tips.com/javascript/difference-between-throttling-and-debouncing-a-javascript-functionhttps://dev-tips.com/javascript/difference-between-throttling-and-debouncing-a-javascript-functionOne of the things that make JavaScript special is events. For example, this enables a specific function to be performed when the browser window is resized or scrolled. However, this kind of events also has its pitfalls: Depending on the complexity of the handler function to be applied and the speed…Sun, 04 Mar 2018 14:59:44 +0000Using the publish/subscribe pattern and a shared event bus to decouple frontendshttps://dev-tips.com/frontend/using-the-publish-subscribe-pattern-and-a-shared-event-bus-to-decouple-frontendshttps://dev-tips.com/frontend/using-the-publish-subscribe-pattern-and-a-shared-event-bus-to-decouple-frontendsIn software engineering, »design patterns« are generalized and reusable solutions to common problems. Within this article, the »publish/subscribe« pattern (»pub/sub«), which is well known and ordinary applied within backends, shall be adapted to frontends. An introduction to pub/sub The main idea of…Sat, 03 Mar 2018 12:47:59 +0000CSSplexity: Applying complexity metrics to a non-programming languagehttps://dev-tips.com/css/cssplexity-applying-complexity-metrics-to-a-non-programming-languagehttps://dev-tips.com/css/cssplexity-applying-complexity-metrics-to-a-non-programming-language»Specificity« is one of the most important (and unsettling?) concepts to understand when writing CSS. It’s a weight applied to a given CSS declaration by which browsers decide which property values are the most relevant to an element and, therefore, will be used. While there are already lots of arti…Sat, 19 Aug 2017 12:35:32 +0000How to log client-side JavaScript errors/exceptions/bugshttps://dev-tips.com/javascript/how-to-log-client-side-javascript-errors-exceptions-bugshttps://dev-tips.com/javascript/how-to-log-client-side-javascript-errors-exceptions-bugsErrors like JavaScript exceptions or XHR failures are one of the biggest challenges that come with developing websites or frontend-driven web applications. Why? Because writing good code is hard. And keeping track of client-side errors is even harder. If there are no errors in my developer console,…Tue, 15 Aug 2017 18:00:32 +0000Hello World, again.https://dev-tips.com/announcements/hello-world-againhttps://dev-tips.com/announcements/hello-world-againSo, here we are. Again. Exactly two years after the last post on the site, I decided to relaunch what was previously known as »JS-Tricks.com« as »Frontend-Development.com« – combined with a new design and a completely new content management system under the hood. While the former site used to be, be…Sun, 09 Apr 2017 17:11:22 +0000Reverse Engineering of Android appshttps://dev-tips.com/android/reverse-engineeringhttps://dev-tips.com/android/reverse-engineeringA very basic introduction to reverse engineering (in general and for Android) as well as some useful tools (apktool, dex2jar, jd-cmd)Thu, 05 Nov 2015 20:11:40 +0000Difference between ».apply()«, ».call()« and ».bind()« in JavaScripthttps://dev-tips.com/javascript/difference-between-apply-call-bind-in-javascripthttps://dev-tips.com/javascript/difference-between-apply-call-bind-in-javascriptWhen working with functions in JavaScript, the value of this and the functions’ arguments are important. .apply(), .call() and .bind() allow you to change this inside a function and pass arguments in different ways. The difference between .apply() and .call() is that .apply() lets you invoke the fun…Wed, 08 Apr 2015 23:05:07 +0000Consynchronous Assurency: How to achieve quasi-concurrency with Array.prototype.forEachhttps://dev-tips.com/javascript/consynchronous-assurency-how-to-achieve-quasi-concurrency-with-array-prototype-foreachhttps://dev-tips.com/javascript/consynchronous-assurency-how-to-achieve-quasi-concurrency-with-array-prototype-foreachOne of the most important concepts in JavaScript is asynchronous programming. The standard model for this technique looks like this: doSomething(some, args, function (error, result) { /* callback */ }); Basically, when you call doSomething(), there is no actual return value. Instead, the results are…Wed, 08 Apr 2015 22:28:12 +0000Complex/variable object keys in JavaScripthttps://dev-tips.com/javascript/complex-variable-object-keys-in-javascripthttps://dev-tips.com/javascript/complex-variable-object-keys-in-javascriptWhile it’s pretty easy to use regular keys within objects in JavaScript, you may need to use complex keys (e.g. variable keys) from time to time. Using square bracket notation, that’s just as easy as regular keys. var demo = {}; demo.a = 'Easy peasy'; demo['b'] = 'Same thing in square bracket notati…Wed, 08 Apr 2015 21:26:53 +0000Passing arguments to another function in JavaScripthttps://dev-tips.com/javascript/passing-arguments-to-another-function-in-javascripthttps://dev-tips.com/javascript/passing-arguments-to-another-function-in-javascriptIf you want to pass arguments to another function in JavaScript, you can use .apply() to have the same access to arguments. function a() { b.apply(this, arguments); } function b() { console.log(arguments); } a('Lorem', 'ipsum');​Wed, 08 Apr 2015 21:17:54 +0000Prefixing immediate functions with a semicolon in JavaScripthttps://dev-tips.com/javascript/prefixing-immediate-functions-with-a-semicolon-in-javascripthttps://dev-tips.com/javascript/prefixing-immediate-functions-with-a-semicolon-in-javascriptAs your scripts may be used together with some other scripts you can’t influence/change, you should always prefix your immediate functions with a semicolon—here’s why. Let’s assume the following function is stored within vendor.js… var someVendorFunction = function () { console.log(arguments); } …an…Wed, 08 Apr 2015 20:43:12 +0000»Truthy« and »falsy« values in JavaScripthttps://dev-tips.com/javascript/truthy-and-falsy-values-in-javascripthttps://dev-tips.com/javascript/truthy-and-falsy-values-in-javascriptThe terms »truthy« and »falsy« are an essential feature (not a bug!) of the JavaScript language, stating that values aren’t just true when talking about »truthy« neither just false when talking about »falsy«. What’s meant is that values coerce to true or false when evaluated in a boolean context. Th…Wed, 08 Apr 2015 19:46:22 +0000How to fix »EACCES« errors with npm on Mac OS Xhttps://dev-tips.com/nodejs/how-to-fix-eacces-errors-with-npm-on-mac-os-xhttps://dev-tips.com/nodejs/how-to-fix-eacces-errors-with-npm-on-mac-os-xIf you installed Node.js and npm using root permissions, you might end up with some nasty npm ERR! Error: EACCES errors as soon as you’re trying to install packages from npm. Consequently, you need to prefix your npm commands using sudo every time you want to install a package—which is anything but…Sun, 15 Feb 2015 17:25:07 +0000