Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
geonorge-shared-partials
Advanced tools
Contains frontend for header used on Geonorge.no, including menu and search.
$ npm install geonorge-shared-partials
Create the following gulpfile.js in the root of your project
var gulp = require("gulp"),
bundleTask = require('./node_modules/geonorge-shared-partials/gulp-tasks/bundle')(gulp),
config = {
url: './node_modules/geonorge-shared-partials/bundle.config.js',
distFolder: 'dist'
};
gulp.task("default", function(){bundleTask(config)});
gulp.task("test", function(){bundleTask(config,"test")});
gulp.task("prod", function(){bundleTask(config,"prod")});
Build js and css
// Dev environment
$ gulp
// Test environment
$ gulp test
// Prod environment
$ gulp prod
Use the html files in your root layout
// C# example
@Html.Raw(File.ReadAllText(Server.MapPath("~/dist/partials/Header.html")))
and include this js somewhere on your site to update the "shopping cart" icon
var orderItems = $.cookie('orderitems');
if (orderItems && orderItems > 0) {
$('.downloads__count').show();
$('.downloads__count').text(orderItems);
}
FAQs
Header for *.geonorge.no sites
We found that geonorge-shared-partials demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 4 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.