Skip to content

Instantly share code, notes, and snippets.

Mohamed Hussain S H shmdhussain

  • Sky News Arabia
  • AbuDhabi, UAE
Block or report user

Report or block shmdhussain

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
shmdhussain / app.js
Last active Aug 29, 2015
Angular Directive Demo Issue
View app.js
// Create a new module
var myApp = angular.module('myApp', ['ngRoute']);
// register a new service
//myApp.value('appName', 'MyCoolApp');
// configure existing services inside initialization blocks.
myApp.config(function($locationProvider,$routeProvider) {
shmdhussain / viewport-info.js
Last active Jan 6, 2018
ViewPort Information
View viewport-info.js
console.log("The Screen Width(these dimensions are measured in device pixels because they never change: they’re a feature of the monitor, and not of the browser.");
console.log("the browser width in css px is (no device pixel)" + window.innerWidth);
console.log("the browser width height in css ps is (no device pixel)" + window.innerHeight);
console.log("the layout viewport width in css px" + document.documentElement.clientWidth);
console.log("the layout viewport height in css px" + document.documentElement.clientHeight);
console.log("the screen device width in dev px is " + screen.width);
console.log("the screen device height in dev px is " + screen.height);
shmdhussain / angularjs-version.js
Created Jan 6, 2018
Get the angularjs version
View angularjs-version.js
shmdhussain / sna-ready.js
Created Jan 6, 2018
SNA-cms-get the dom ready SNAP object, execute this in console and get which is triggered when page is initializing
View sna-ready.js
shmdhussain / angular-enable-debug.js
Created Jan 6, 2018
enable angualr debugging from browser console
View angular-enable-debug.js
shmdhussain / debugger-timeout.js
Created Jan 6, 2018
Debugger timeout, when debugging mouse hover, run this in console, and check the mouse over actions
View debugger-timeout.js
}, 5000);
shmdhussain / enable-body-edit.js
Created Jan 6, 2018
make the whole body , content editable, useful for just changing the content in page for demo
View enable-body-edit.js
shmdhussain / ellipsis.css
Created Jan 6, 2018
Ellipsis CSS -quick CSS
View ellipsis.css
@mixin ellipsis() {
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
@mixin word-wrap() {
overflow-wrap: break-word;
word-wrap: break-word;
-ms-word-break: break-all;
word-break: break-word;
View add-script-body.js
/*START: Create Script Tag and append in last line of body*/
function addScript( src ) {
var s = document.createElement( 'script' );
s.setAttribute( 'src', src );
document.body.appendChild( s );
/*END: Create Script Tag and append in last line of body*/
You can’t perform that action at this time.