Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
The really, really minimalistic static site generator. Manage translations statically, without any pesky JavaScript for rendering dynamic chunks of localized text.
Traditionally, managing translations of a website statically would look something like this:
::
__ root
|
|__ scripts
| |__ scripts.js
|
|__ styles
| |__ styles.css
|
|__ lang
|__ en
| |__ index.html
| |__ about.html
| |__ ...
|
|__ fr
|__ index.html
|__ about.html
|__ ...
Here, we have a website with two or more English pages that we also
translated into French. This works, but what happens when I want to make
some changes to index.html
? Now, I need to copy those changes over
to the fr
folder and adapt. When these phrases are wrapped with new
UI components, It gets worse the more languages you add.
A problem like this would take a static site generator to solve, but not just any static site generator would do the trick. This generator must have a focus on translation, allowing you to build several copies of the same page based on different localization files.
Now, you can leave the translation to the globalization team and focus on your code.
So as you can tell, Ampersand is a pretty straightforward static site generator. Some may even argue that it doesn’t do much. This is because Ampersand is a minimalistic static site generator. But of course, all static site generators mention minimalism in their mission statement so saying it here doesn’t mean much. Never the less, Ampersand aims to do what it’s supposed to do without jumping through too many hoops that don’t help it achieve its goal.
Setting up Ampersand is fairly simple if you have pip
. For those of
you who don’t, python.org
_ has it documented.
::
$ pip install ampersand
For a bleeding edge and developer version, you can clone the repository:
::
$ git clone https://github.com/natejms/ampersand.git
$ cd ampersand
$ pip install .
To learn more about the usage of Ampersand, check out the documentation
_
Interested in making a contribution? Here’s a few places where you might be able to help out:
More information can be found in the CONTRIBUTING.md file of this repository.
.. _python.org: https://packaging.python.org/installing/ .. _the documentation: https://github.com/natejms/ampersand/wiki
FAQs
The really, really minimalistic static site generator
We found that ampersand demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer 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
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.