New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

html-telegram-bot-api

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

html-telegram-bot-api - npm Package Compare versions

Comparing version 0.2.7 to 0.2.8

2

package.json
{
"name": "html-telegram-bot-api",
"description": "Now you can write Telegram bots in HTML.",
"version": "0.2.7",
"version": "0.2.8",
"main": "src/index.js",

@@ -6,0 +6,0 @@ "scripts": {

@@ -23,3 +23,3 @@ # html-telegram-bot-api

```console
$ html-telegram-bot [options] <path-to-html-file>
$ html-telegram-bot [options] <path/to/html/file>
```

@@ -30,3 +30,3 @@

```console
$ html-telegram-bot-api [options] <path-to-html-file>
$ html-telegram-bot-api [options] <path/to/html/file>
```

@@ -69,2 +69,6 @@

## Related
* [css-telegram-bot-api](https://github.com/Bannerets/css-telegram-bot-api)
## CLI Options

@@ -71,0 +75,0 @@

@@ -7,19 +7,24 @@ const fs = require('fs')

let filename = ''
program
.version(pkg.version)
.arguments('<path-to-html-file>')
.action(arg => (filename = arg))
.arguments('<path/to/html/file>')
.action(start)
.parse(process.argv)
const html = fs.readFileSync(filename).toString()
if (program.args.length === 0) {
console.error('filename is required')
process.exit(1)
}
const parser = new Parser(html)
function start (filename) {
const html = fs.readFileSync(filename).toString()
const { token, commands } = parser.parseHTML()
const parser = new Parser(html)
const bot = new TelegramBot(token)
const { token, commands } = parser.parseHTML()
bot.addCommands(commands)
bot.startPolling()
const bot = new TelegramBot(token)
bot.addCommands(commands)
bot.startPolling()
}

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc