Security News
PyPI Introduces Digital Attestations to Strengthen Python Package Security
PyPI now supports digital attestations, enhancing security and trust by allowing package maintainers to verify the authenticity of Python packages.
simple-web-cli
Advanced tools
⚡ A simple compiler to automate the development in HTML, CSS, JavaScript and PHP languages using FTP connection to deploy the processed files automatically to the final server.
A simple compiler to automate the development in the HTML, CSS/Sass, JavaScript and PHP languages using Localhost Live Reloader or FTP connection to deploy files processed automatically to the final server.
npm i simple-web-cli -D # to download the dependencies
npx sw # to start the service
scr
is the directory of developmentdist
is the directory with the compiled codenpx sw
or npx sw start
: prepares the environment and starts the servicenpx sw init
: prepares the environment without starting the servicenpx sw build
: compiles the contents from src
and zips it to release.zip
src
.You can import .html
files recursively, based on the scss
import, for example:
<html>
<body>
<!-- import('./views/_header.html') -->
<section>
<!-- import('./views/_main.html') -->
</section>
<!-- import('../_footer.html') -->
</body>
</html>
In JavaScript (web), it's possible to import local modules saved into .library
, for example:
.library/my-script/index.js
/* for entire file import */
require('web/my-script');
/* to import the default module into a variable */
const my_script = require('web/my-script');
/* to import the modules by destronstuct variables */
const { my_script1, my_script2 } = require('web/my-script');
/* to import the module into a variable with a custom name */
const my_name_var = require('web/my-script').my_script1;
In the file .swrc.js
, just insert the acess infos:
{
ftp: {
root: '_ROOT_DIRECTORY_',
host: '_IP_',
user: '_USER_',
pass: '_PASSWORD_',
secure: true || 'explict'
}
}
Assuming the root
directory is /var/www
, the input and output of the directories would be:
src/html/index.html
dist/html/index.html
/var/www/html/index.html
INPUT
<div>
<h1>Title</h1>
<p>Paragraph</p>
</div>
OUTPUT
<div><h1>Title</h1><p>Paragraph</p></div>
INPUT
div {
display: flex;
}
OUTPUT
div{display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex}
INPUT
(() => {
require('web/selector');
const element = s('body');
const inElement = sEl(element, 'div');
const elements = sAll('.class');
const elementsInElement = sElAll(element, '.class');
})();
OUTPUT
"use strict";!function(){var e,c,l,r,t=(e="body",document.querySelector(e));c="div",t.querySelector(c),l=".class",document.querySelectorAll(l),r=".class",t.querySelectorAll(r)}();
INPUT
<?
$var = 'text'
?>
<div>
<?=$var?>
</div>
OUTPUT
<?php $var='text'?><div><?=$var?></div>
INPUT
# comment
<Directory /var/www/>
# another comment
Options Indexes FollowSymLinks MultiViews
</Directory>
OUTPUT
<Directory /var/www/>
Options Indexes FollowSymLinks MultiViews
</Directory>
.swrc.js
{
strings: {
'*token*': {
start: '0cfcda42c340dad5616e0b7449a5634b',
build: '0cfcda42c340dad5616e0b7449a5634b'
},
'*site-name*': {
start: 'dev.weslley.io',
build: 'weslley.io'
}
}
}
INPUT
<?
$_POST['*token*'];
$site = '*site-name*';
OUTPUT DEV (npx sw)
<?php $_POST['0cfcda42c340dad5616e0b7449a5634b'];$site='dev.weslley.io';
OUTPUT BUILD (npx sw build)
<?php $_POST['0cfcda42c340dad5616e0b7449a5634b'];$site='weslley.io';
.swrc.js
Contributors | GitHub |
---|---|
Author | |
Translate en-US | |
Translate Review |
Made with sadness and sorrow in rainy nights by Weslley Araújo 🥺
FAQs
⚡ A simple compiler to automate the development in HTML, CSS, SCSS, JavaScript, TypeScript and PHP languages, focused on Shared Hosts and using SFTP or FTP to deploy files processed automatically to final server.
We found that simple-web-cli demonstrated a not healthy version release cadence and project activity because the last version was released 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.
Security News
PyPI now supports digital attestations, enhancing security and trust by allowing package maintainers to verify the authenticity of Python packages.
Security News
GitHub removed 27 malicious pull requests attempting to inject harmful code across multiple open source repositories, in another round of low-effort attacks.
Security News
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.