npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

polyglot-code

v1.0.10

Published

Write console logs in 'any' programming language

Downloads

7

Readme

Polyglot Code!

language language

:vhs: Clone me!

Clone or download the project:

git clone https://github.com/cosasdepuma/polyglot-code.git Polyglot
  [ or ]
git clone https://gitlab.com/cosasdepuma/polyglot-code.git Polyglot

cd Polyglot

:see_no_evil: Test it!

:package: Run all the unitary tests through NodeJS:

cd javascript
npm i
npm test

:snake: Run all the unitary tests using Python:

cd python
python2 test/test.py
python3 test/test.py

:electric_plug: Requirements

Polyglot does not require anything!

:inbox_tray: Download

Download Polyglot using npm:

npm install polyglot-code

Download Polyglot using pip (depending on your version):

pip install polyglot-code
pip2 install polyglot-code
pip3 install polyglot-code

:runner: Usage

Import Polyglot into your NodeJS file:

require('polyglot-code')

Import Polyglot into your Python file:

import polyglot

:speech_balloon: Available Languages!

:coffee: JavaScript

// No new-line logs
printf('C')
IO.write('Elixir')
fmt.Printf('Go')
putStr('Haskell')
io.write('Lua')
fprintf('Matlab')
Write('Pascal')
write('Pike')

// New-line logs
trace('ActionScript')
WriteF('AmigaE')
Response.Write('ASP')
putschar('B')
puts('C')
Console.println('C#')
Console.WriteLine('C#')
writeln('D')
std.stdio.writeln('D')
print('Dart')
Writeln('Delphi')
IO.puts('Elixir')
fmt.Println('Go')
putStrLn('Haskell')
System.out.println('Java')
console.log('JavaScript')
println('Kotlin')
disp('Matlab')
echo('Nim')
NSLog('Objetive-C')
writeln('Pascal')
writeln('Pike')
println('Processing')
PrintN('PureBasic')
print('Python')
p('Ruby')

:snake: Python

# No new-line logs
printf("C")
cout << "C++"
IO.write("Elixir")
fmt.Print("Go")
fmt.Printf("Go")
putStr("Haskell")
System.out.printf("Java")
io.write("Lua")
fprintf("Matlab")
write("Pike")
System.Console.Write("VB.NET")

# New-line logs
print("Python")
trace("ActionScript")
Ada.Text_IO.Put_Line("Ada")
WriteF("AmigaE")
Response.Write("ASP")
putchar("B")
puts("C")
Console.println("C#")
Console.WriteLine("C#")
cout << "C++" << endl
Qout("Clipper")
writeln("D")
std.stdio.writeln("D")
Writeln("Delphi")
IO.puts("Elixir")
fmt.Println("Go")
putStrLn("Haskell")
System.out.println("Java")
console.log("JavaScript")
println("Kotlin")
Print["Mathematica"]
disp("Matlab")
echo("Nim")
NSLog("Objetive-C")
writeln("Pascal")
writeln("Pike")
PrintN("PureBasic")
p("Ruby")
Debug.Log("Unity3D")
System.Console.WriteLine("VB.NET")

:octopus: Support the developer!

Everything I do and publish can be used for free whenever I receive my corresponding merit.

Anyway, if you want to help me in a more direct way, you can leave me a tip by clicking on this badge:

:earth_africa: Scheme of contents

Polyglot-Code
 < Repository >
|__ .gitignore
|__ .repository
  |__ odd.jpeg
|__ LICENSE
|__ README.md
< JavaScript >
|__ javascript
  |__ package.json
  |__ lib
    |__ polyglot.js
  |__ test
    |__ test.js
< Python >
|__ python
  |__ lib
    |__ __init__.py
    |__ polyglot.py
  |__ test
    |__ test.py

Please contact with Kike Puma if you need more information.