Skip to content

Commit

Permalink
feat(lib): support for angular v13 (#164)
Browse files Browse the repository at this point in the history
* replace tslint with eslint
* replace protractor with cypress
* update third party libraries
* change circleci configuration
  • Loading branch information
Jonnyprof committed Oct 21, 2022
1 parent 582bfc7 commit a8212ea
Show file tree
Hide file tree
Showing 45 changed files with 7,220 additions and 7,738 deletions.
33 changes: 16 additions & 17 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@
# - https://circleci.com/docs/2.0/circleci-images/

# CirlceCI Configuration
version: 2
version: 2.1

orbs:
browser-tools: circleci/browser-tools@1.2.3

# References
references:
Expand All @@ -11,10 +14,10 @@ references:
~/app

image_node: &image_node
image: circleci/node:12.14.1
image: cimg/node:16.18.0

image_node_browsers: &image_node_browsers
image: circleci/node:12.14.1-browsers
image: cimg/node:16.18.0-browsers

job_defaults: &job_defaults
working_directory: *working_directory
Expand All @@ -28,22 +31,11 @@ references:

restore_yarn_cache: &restore_yarn_cache
restore_cache:
key: dependency-cache-{{ checksum "package.json" }}
key: dependency-cache-{{ checksum "yarn.lock" }}

restore_yarn_cache_peer: &restore_yarn_cache_peer
restore_cache:
key: dependency-cache-peer-{{ checksum "package.json" }}

update_chrome_driver: &update_chrome_driver
run:
name: Update Chrome Driver
command: |
sudo apt-get update
sudo apt-get install lsb-release libappindicator3-1
curl -L -o google-chrome.deb https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
sudo dpkg -i google-chrome.deb
sudo sed -i 's|HERE/chrome"|HERE/chrome" --no-sandbox|g' /opt/google/chrome/google-chrome
rm google-chrome.deb
key: dependency-cache-peer-{{ checksum "yarn.lock" }}

# Jobs
jobs:
Expand All @@ -57,12 +49,19 @@ jobs:
name: Install NodeJS Dependencies via YARN
command: yarn install
- save_cache:
key: dependency-cache-{{ checksum "package.json" }}
key: dependency-cache-{{ checksum "yarn.lock" }}
paths:
- node_modules
test_spec:
<<: *job_defaults_browsers
steps:
- browser-tools/install-chrome
- browser-tools/install-chromedriver
- run:
command: |
google-chrome --version
chromedriver --version
name: Check install
- checkout
- *restore_yarn_cache
- *restore_yarn_cache_peer
Expand Down
51 changes: 51 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
{
"root": true,
"ignorePatterns": [
"projects/**/*"
],
"overrides": [
{
"files": [
"*.ts"
],
"parserOptions": {
"project": [
"tsconfig.json",
"e2e/tsconfig.json"
],
"createDefaultProgram": true
},
"extends": [
"plugin:@angular-eslint/recommended",
"plugin:@angular-eslint/template/process-inline-templates"
],
"rules": {
"@angular-eslint/component-selector": [
"error",
{
"prefix": "ngx",
"style": "kebab-case",
"type": "element"
}
],
"@angular-eslint/directive-selector": [
"error",
{
"prefix": "ngx",
"style": "camelCase",
"type": "attribute"
}
]
}
},
{
"files": [
"*.html"
],
"extends": [
"plugin:@angular-eslint/template/recommended"
],
"rules": {}
}
]
}
33 changes: 10 additions & 23 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,55 +1,42 @@
# See http://help.github.com/ignore-files/ for more about ignoring files.

# compiled output
# Compiled output
/dist
/tmp
/out-tsc
# Only exists if Bazel was run
/bazel-out

# dependencies
# Node
/node_modules

# profiling files
chrome-profiler-events*.json
speed-measure-plugin*.json
npm-debug.log
yarn-error.log

# IDEs and editors
/.idea
.idea/
.project
.classpath
.c9/
*.launch
.settings/
*.sublime-workspace

# IDE - VSCode
# Visual Studio Code
.vscode/*
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json
.history/*

# misc
/.sass-cache
# Miscellaneous
/.angular/cache
.sass-cache/
/connect.lock
/coverage
/libpeerconnection.log
npm-debug.log
yarn-error.log
testem.log
/typings

# System Files
# System files
.DS_Store
Thumbs.db

# ng-packagr
.ng_build

# Test Reports
reports

# Documentation
documentation
4 changes: 4 additions & 0 deletions .husky/commit-msg
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"

yarn commitlint --edit $1 --extends "@commitlint/config-angular"
4 changes: 4 additions & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"

npm test
5 changes: 0 additions & 5 deletions .huskyrc.json

This file was deleted.

6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -105,10 +105,14 @@ Current Angular Version
[![npm version](https://img.shields.io/npm/v/%40angular%2Fcore.svg?style=flat-square)](https://www.npmjs.com/~angular)

## Installation
Angular 8 and 9
Angular 13
```sh
$ npm install @nicky-lenaers/ngx-scroll-to
```
Angular 8 and 9
```sh
$ npm install @nicky-lenaers/ngx-scroll-to@'9'
```
Angular 7
```sh
$ npm install @nicky-lenaers/ngx-scroll-to@'2'
Expand Down

0 comments on commit a8212ea

Please sign in to comment.