at-builder 1.2.4 → 1.2.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/.eslintrc CHANGED
@@ -15,7 +15,8 @@
15
15
  "navigator": "readonly",
16
16
  "window": "readonly",
17
17
  "utag_data": "readonly",
18
- "utag": "readonly"
18
+ "utag": "readonly",
19
+ "process": "readonly"
19
20
  },
20
21
  "ignorePatterns": [
21
22
  "webpack.config.js",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "at-builder",
3
- "version": "1.2.4",
3
+ "version": "1.2.6",
4
4
  "main": "bin/index.js",
5
5
  "bin": {
6
6
  "atb": "bin/index.js"
@@ -10,7 +10,7 @@
10
10
  "build:atb:dev": "tsc -w",
11
11
  "atb:build:prod": "cross-env NODE_ENV=production webpack",
12
12
  "atb:build:dev": "webpack -- -w",
13
- "atb:build:dev:puppeteer": "webpack -- -w & npm run puppeteer",
13
+ "atb:build:dev:puppeteer": "webpack -- -w & npm run atb:puppeteer",
14
14
  "atb:puppeteer": "node puppeteer.js $b",
15
15
  "atb:plop:new:activity": "plop page",
16
16
  "atb:build:deploy": "node lib/at-deploy.js"
@@ -55,20 +55,19 @@
55
55
  "typescript": "^5.7.3",
56
56
  "webpack": "^5.72.0",
57
57
  "webpack-cli": "^6.0.1",
58
- "wrapper-webpack-plugin": "^2.1.0"
59
- },
60
- "description": "[![npm version](https://badge.fury.io/js/at-builder.svg)](https://www.npmjs.com/package/at-builder) [![License](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)",
61
- "directories": {
62
- "lib": "lib",
63
- "test": "test"
64
- },
65
- "devDependencies": {
58
+ "wrapper-webpack-plugin": "^2.1.0",
66
59
  "@babel/runtime": "^7.28.3",
67
60
  "@eslint/js": "^9.20.0",
68
61
  "globals": "^15.15.0",
69
62
  "kleur": "^4.1.5",
70
63
  "typescript-eslint": "^8.24.1"
71
64
  },
65
+ "description": "[![npm version](https://badge.fury.io/js/at-builder.svg)](https://www.npmjs.com/package/at-builder) [![License](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)",
66
+ "directories": {
67
+ "lib": "lib",
68
+ "test": "test"
69
+ },
70
+ "devDependencies": {},
72
71
  "repository": {
73
72
  "type": "git",
74
73
  "url": "git+https://github.com/upesenga/at-builder.git"
package/plopfile.js CHANGED
@@ -1,6 +1,3 @@
1
- /* eslint-disable no-undef */
2
- /* eslint-disable @typescript-eslint/no-require-imports */
3
-
4
1
  const components = require("./.plop/generators/components");
5
2
  const path = require('path');
6
3
  const dotenv = require('dotenv');
package/puppeteer.js CHANGED
@@ -1,11 +1,11 @@
1
+ /* eslint-disable no-undef */
1
2
  import dotenv from 'dotenv';
2
3
  import path from 'path';
3
4
  import puppeteer from 'puppeteer';
4
5
  import fs from 'fs';
5
6
  import chokidar from 'chokidar';
6
- import { executionPath } from process.env;
7
+ const executionPath = process.env.executionPath || process.cwd();
7
8
  dotenv.config({ path: path.join(executionPath, ".env") });
8
- //const watchConfig = "./../watch-config.json";
9
9
 
10
10
  let watchConfig = '';
11
11
  try {
@@ -43,18 +43,13 @@ const watcher = chokidar.watch("file", {
43
43
  await this.page.$eval('#pwd', el => el.value = '');
44
44
  }
45
45
 
46
- async autoFillLoginDetails() {
47
- await this.page.$eval('#email', el => el.value = '');
48
- await this.page.$eval('#pwd', el => el.value = '');
49
- }
50
-
51
46
  async openTab() {
52
47
  this.page = await this.browser.pages();
53
48
  this.page = this.page[0];
54
49
  this.page.setDefaultTimeout(3e8);
55
50
  // await this.page.setViewport({ width: 1792, height: 768 });
56
51
  await this.page.setViewport({ width: 1920, height: 1080 });
57
- await this.page.goto(process.env.PUPPETEER_LANDING_PAGE);
52
+ await this.page.goto(process.env.PUPPETEER_LANDING_PAGE || "https://www.google.com");
58
53
 
59
54
  // inject script
60
55
  this.injectCodeSnippet();
@@ -69,6 +64,7 @@ const watcher = chokidar.watch("file", {
69
64
 
70
65
  await this.page.reload();
71
66
  this.injectCodeSnippet();
67
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
72
68
  } catch (error) {
73
69
 
74
70
  }