Tutorial by Examples: c

To publish public repositories with a free npm account, you initially need to publish the module with access of public. One way to do this is to set the config for npm to read in packages.json as follows: "publishConfig": { "access": "public" }, you can also use...
Download the Atlassian conversion utility here. This utility requires Java, so please ensure that you have the Java Runtime Environment JRE installed on the machine you plan to do the conversion. Use the command java -jar svn-migration-scripts.jar verify to check if your machine is missing any of t...
The macro WITH-INPUT-FROM-STRING can be used to make a stream from a string. (with-input-from-string (str "Foobar") (loop for i from 0 for char = (read-char str nil nil) while char do (format t "~d: ~a~%" i char))) ; 0: F ; 1: o ; 2: o ; 3: b ;...

CSS

This binding will apply the supplied CSS class to the element. Static classes are applied when the given conditions are loosely-evaluated to true. Dynamic classes use the value of an observable or computed. page.html <p data-bind="css: { danger: isInDanger }">Checks external expres...
Method stopLoading() stops the current loading process of the webview. Swift webview.stopLoading() Objective-C [webview stopLoading];
Swift webview.reload() Objective-C [webview reload];
Whatever you do to customize Vim, it should NEVER happen outside of $HOME: on Linux, BSD and Cygwin, $HOME is usually /home/username/, on Mac OS X, $HOME is /Users/username/, on Windows, $HOME is usually C:\Users\username\. The canonical location for your vimrc and your vim directory is at ...
Don't forget the bang to allow Vim to overwrite that command next time you reload your vimrc. Custom commands must start with an uppercase character. Examples command! MyCommand call SomeFunction() command! MyOtherCommand command | Command | command See :help user-commands.
Don't forget the bang to allow Vim to overwrite that function next time you reload the script where the function is defined. Custom functions must start either with an uppercase character (global functions), or with s: (script local functions), or they must be prefixed with the name associated to...
Autocommand groups are good for organization but they can be useful for debugging too. Think of them as small namespaces that you can enable/disable at will. Example augroup MyGroup " Clear the autocmds of the current group to prevent them from piling " up each time you rel...
if v:version >= 704 " Do something if Vim is the right version. endif if has('patch666') " Do something if Vim has the right patch-level. endif if has('feature') " Do something if Vim is built with 'feature'. endif See :help has-patch and :help feature-li...
By default the built-in Request Localization middleware only supports setting culture via query, cookie or Accept-Language header. This example shows how create a middleware which allows to set the culture as part of the path like in /api/en-US/products. This example middleware assumes the locale t...
Avoid Ambiguity The name of classes, structures, functions and variables should avoid ambiguity. Example: extension List { public mutating func remove(at position: Index) -> Element { // implementation } } The function call to this function will then look like this: li...
Types & Protocols Type and protocol names should start with an uppercase letter. Example: protocol Collection {} struct String {} class UIView {} struct Int {} enum Color {} Everything else... Variables, constants, functions and enumeration cases should start with a lowercase letter. Exa...
By default, one should subscribe to event using inspector, but sometimes it's better to do it in code. In this example we subscribe to click event of a button in order to handle it. using UnityEngine; using UnityEngine.UI; [RequireComponent(typeof(Button))] public class AutomaticClickHandler :...
Using the baseline-shift parameter, you can specify super- or subscript. But this is not supported by all major browsers. <svg xmlns="http://www.w3.org/2000/svg"> <text x="10" y="20">x<tspan baseline-shift="super">2</tspan></te...
In cases such as restoring a database dump, or otherwise wishing to push some information through a pipe from the host, you can use the -i flag as an argument to docker run or docker exec. E.g., assuming you want to put to a containerized mariadb client a database dump that you have on the host, in...
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"> <line x1="10" y1="10" x2="100" y2="100" stroke="red" stroke-width="10" /> <line x1="100" y1="10&...
docker inspect <image> The output is in JSON format. You can use jq command line utility to parse and print only the desired keys. docker inspect <image> | jq -r '.[0].Author' The above command will shows author name of the images.
Tag syntax Parameters AttributeRequiredTypeDefaultDescriptionconditiontruestringCondition that manages the loop. Cannot contain math symbols like <, > or =. Must use ColdFusion text implementations like less than, lt, greater than, gt, equals or eq. Final value of x is 5. <cfset x = 0 /...

Page 241 of 826