diff --git a/.github/ISSUE_TEMPLATE/BUG_REPORT.yml b/.github/ISSUE_TEMPLATE/BUG_REPORT.yml index 70b494ea5b..90383552ef 100644 --- a/.github/ISSUE_TEMPLATE/BUG_REPORT.yml +++ b/.github/ISSUE_TEMPLATE/BUG_REPORT.yml @@ -37,7 +37,6 @@ body: InstantSearch.js React InstantSearch Vue InstantSearch - Angular InstantSearch diff --git a/README.md b/README.md index 4065044806..43190a8050 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@

- InstantSearch is a JavaScript library for building performant and instant search experiences in vanilla JS, React, Vue and Angular with Algolia. + InstantSearch is a JavaScript library for building performant and instant search experiences in vanilla JS, React and Vue with Algolia.

@@ -14,11 +14,11 @@ [InstantSearch][instantsearch-docs] is a JavaScript library that lets you create an instant-search result experience using [Algolia][algolia-website]’s search API. -There are multiple wrappers for popular frameworks, such as [React InstantSearch][react-instantsearch-docs], [Vue InstantSearch][vue-instantsearch-docs], and [Angular InstantSearch][angular-instantsearch-docs]. +There are multiple wrappers for popular frameworks, such as [React InstantSearch][react-instantsearch-docs] and [Vue InstantSearch][vue-instantsearch-docs]. It is part of the InstantSearch family which is designed for different platforms: -**InstantSearch** | [Angular InstantSearch][instantsearch-angular-github] | [InstantSearch Android][instantsearch-android-github] | [InstantSearch iOS][instantsearch-ios-github] +**InstantSearch** | [InstantSearch Android][instantsearch-android-github] | [InstantSearch iOS][instantsearch-ios-github]
Table of contents @@ -81,10 +81,8 @@ InstantSearch is [MIT licensed][license-url]. [instantsearch-docs]: https://www.algolia.com/doc/guides/building-search-ui/what-is-instantsearch/js/?utm_source=instantsearch.js&utm_campaign=repository 'InstantSearch.js documentation' [react-instantsearch-docs]: https://www.algolia.com/doc/guides/building-search-ui/what-is-instantsearch/react/?utm_source=instantsearch.js&utm_campaign=repository 'React InstantSearch documentation' [vue-instantsearch-docs]: https://www.algolia.com/doc/guides/building-search-ui/what-is-instantsearch/vue/?utm_source=instantsearch.js&utm_campaign=repository 'Vue InstantSearch documentation' -[angular-instantsearch-docs]: https://www.algolia.com/doc/guides/building-search-ui/what-is-instantsearch/angular/?utm_source=instantsearch.js&utm_campaign=repository 'Angular InstantSearch documentation' [instantsearch-android-github]: https://github.com/algolia/instantsearch-android [instantsearch-ios-github]: https://github.com/algolia/instantsearch-ios -[instantsearch-angular-github]: https://github.com/algolia/angular-instantsearch [contributing-bugreport]: https://github.com/algolia/instantsearch/issues/new?template=BUG_REPORT.yml&labels=triage [contributing-featurerequest]: https://github.com/algolia/instantsearch/discussions/new?category=ideas&labels=triage&title=Feature%20request%3A%20 [contributing-newissue]: https://github.com/algolia/instantsearch/issues/new?labels=triage diff --git a/examples/js/e-commerce-umd/src/theme.css b/examples/js/e-commerce-umd/src/theme.css index e2313f7052..ad38876d92 100644 --- a/examples/js/e-commerce-umd/src/theme.css +++ b/examples/js/e-commerce-umd/src/theme.css @@ -10,11 +10,6 @@ a[class^='ais-'] { text-decoration: none; } -/* - We need to target the root element because Angular InstantSearch - creates web components which are not targetable with the `*` selector. -*/ -[class^='ais-'][class$='--disabled'], /* We need to target all elements for widgets containing multiple sub elements (e.g. RangeSlider) diff --git a/examples/js/e-commerce/src/theme.css b/examples/js/e-commerce/src/theme.css index e2313f7052..ad38876d92 100644 --- a/examples/js/e-commerce/src/theme.css +++ b/examples/js/e-commerce/src/theme.css @@ -10,11 +10,6 @@ a[class^='ais-'] { text-decoration: none; } -/* - We need to target the root element because Angular InstantSearch - creates web components which are not targetable with the `*` selector. -*/ -[class^='ais-'][class$='--disabled'], /* We need to target all elements for widgets containing multiple sub elements (e.g. RangeSlider) diff --git a/examples/js/media/src/theme.css b/examples/js/media/src/theme.css index a4ae06b7f2..662caf8a58 100644 --- a/examples/js/media/src/theme.css +++ b/examples/js/media/src/theme.css @@ -10,11 +10,6 @@ a[class^='ais-'] { text-decoration: none; } -/* - We need to target the root element because Angular InstantSearch - creates web components which are not targetable with the `*` selector. -*/ -[class^='ais-'][class$='--disabled'], /* We need to target all elements for widgets containing multiple sub elements (e.g. RangeSlider) diff --git a/examples/react/e-commerce/Theme.css b/examples/react/e-commerce/Theme.css index 263d67f06d..6c4a978fb3 100644 --- a/examples/react/e-commerce/Theme.css +++ b/examples/react/e-commerce/Theme.css @@ -10,11 +10,6 @@ a[class^='ais-'] { text-decoration: none; } -/* - We need to target the root element because Angular InstantSearch - creates web components which are not targetable with the `*` selector. -*/ -[class^='ais-'][class$='--disabled'], /* We need to target all elements for widgets containing multiple sub elements (e.g. RangeSlider) diff --git a/examples/vue/e-commerce/src/Theme.css b/examples/vue/e-commerce/src/Theme.css index cdb61df4a8..370747d6ad 100644 --- a/examples/vue/e-commerce/src/Theme.css +++ b/examples/vue/e-commerce/src/Theme.css @@ -10,11 +10,6 @@ a[class^='ais-'] { text-decoration: none; } -/* - We need to target the root element because Angular InstantSearch - creates web components which are not targetable with the `*` selector. -*/ -[class^='ais-'][class$='--disabled'], /* We need to target all elements for widgets containing multiple sub elements (e.g. RangeSlider) diff --git a/packages/create-instantsearch-app/README.md b/packages/create-instantsearch-app/README.md index 5e25792e2b..9af8acd9e9 100644 --- a/packages/create-instantsearch-app/README.md +++ b/packages/create-instantsearch-app/README.md @@ -4,7 +4,7 @@ [![Version][version-svg]][package-url] [![License][license-image]][license-url] [![Build Status][ci-svg]][ci-url] -`create-instantsearch-app` is a command line utility that helps you quick start your InstantSearch app using any [Algolia][algolia-website] InstantSearch flavor ([InstantSearch.js][instantsearchjs-github], [React InstantSearch][react-instantsearch-github], [Vue InstantSearch][vue-instantsearch-github], [Angular InstantSearch][angular-instantsearch-github], [InstantSearch iOS][instantsearch-ios-github] and [InstantSearch Android][instantsearch-android-github]). +`create-instantsearch-app` is a command line utility that helps you quick start your InstantSearch app using any [Algolia][algolia-website] InstantSearch flavor ([InstantSearch.js][instantsearchjs-github], [React InstantSearch][react-instantsearch-github], [Vue InstantSearch][vue-instantsearch-github], [InstantSearch iOS][instantsearch-ios-github] and [InstantSearch Android][instantsearch-android-github]).

Preview @@ -50,9 +50,7 @@ cd my-app yarn start ``` -> **Important** -> Selecting 'Y' when being prompted to ‘Enable user events’ activates the [`insights`](https://www.algolia.com/doc/api-reference/widgets/instantsearch/js/#widget-param-insights) option for compatible templates, allowing Algolia to process your user Events. Events can unlock powerful features, enhancing your application's effectiveness and we encourage you to consider enabling this valuable functionality. Please review our [API reference](https://www.algolia.com/doc/api-reference/widgets/instantsearch/js/#widget-param-insights) for more details about Events collection and settings. - +> **Important** Selecting 'Y' when being prompted to ‘Enable user events’ activates the [`insights`](https://www.algolia.com/doc/api-reference/widgets/instantsearch/js/#widget-param-insights) option for compatible templates, allowing Algolia to process your user Events. Events can unlock powerful features, enhancing your application's effectiveness and we encourage you to consider enabling this valuable functionality. Please review our [API reference](https://www.algolia.com/doc/api-reference/widgets/instantsearch/js/#widget-param-insights) for more details about Events collection and settings. ## Usage @@ -89,7 +87,6 @@ Supported templates are: - [`React InstantSearch`][react-instantsearch-github] - [`React InstantSearch Native`][react-instantsearch-github] - [`Vue InstantSearch`][vue-instantsearch-github] -- [`Angular InstantSearch`][angular-instantsearch-github] - [`InstantSearch iOS`][instantsearch-ios-github] - [`InstantSearch Android`][instantsearch-android-github] @@ -158,7 +155,6 @@ You can use the web templates on CodeSandbox: - [InstantSearch.js](https://codesandbox.io/s/github/algolia/instantsearch/tree/templates/instantsearch.js) - [React InstantSearch](https://codesandbox.io/s/github/algolia/instantsearch/tree/templates/react-instantsearch) - [Vue InstantSearch](https://codesandbox.io/s/github/algolia/instantsearch/tree/templates/vue-instantsearch) -- [Angular InstantSearch](https://codesandbox.io/s/github/algolia/instantsearch/tree/templates/angular-instantsearch) - [Autocomplete.js](https://codesandbox.io/s/github/algolia/instantsearch/tree/templates/autocomplete.js) - [JavaScript Client](https://codesandbox.io/s/github/algolia/instantsearch/tree/templates/javascript-client) - [JavaScript Helper](https://codesandbox.io/s/github/algolia/instantsearch/tree/templates/javascript-helper) @@ -198,7 +194,6 @@ Create InstantSearch App is [MIT licensed](LICENSE). [instantsearchjs-github]: https://github.com/algolia/instantsearch/tree/master/packages/instantsearch.js [react-instantsearch-github]: https://github.com/algolia/instantsearch/tree/master/packages/react-instantsearch [vue-instantsearch-github]: https://github.com/algolia/instantsearch/tree/master/packages/vue-instantsearch -[angular-instantsearch-github]: https://github.com/algolia/angular-instantsearch [instantsearch-ios-github]: https://github.com/algolia/instantsearch-ios [instantsearch-android-github]: https://github.com/algolia/instantsearch-android [contributing-bugreport]: https://github.com/algolia/instantsearch/issues/new?template=BUG_REPORT.yml&labels=triage,Library%3A%20Create+InstantSearch+App diff --git a/packages/create-instantsearch-app/docs/deploy.md b/packages/create-instantsearch-app/docs/deploy.md index ec3366d3c2..e9cccd1cca 100644 --- a/packages/create-instantsearch-app/docs/deploy.md +++ b/packages/create-instantsearch-app/docs/deploy.md @@ -1,6 +1,6 @@ # Deploy an InstantSearch app -Create InstantSearch App generates applications that are ready to be deployed. They rely on bundlers and framework toolkits (Parcel, Create React App, Vue CLI, Angular CLI, etc.). +Create InstantSearch App generates applications that are ready to be deployed. They rely on bundlers and framework toolkits (Parcel, Create React App, Vue CLI, etc.). Your app can be deployed in a single command, assuming you're located in its folder. diff --git a/packages/create-instantsearch-app/e2e/__snapshots__/templates.test.js.snap b/packages/create-instantsearch-app/e2e/__snapshots__/templates.test.js.snap index 89c5d02e69..9f24307023 100644 --- a/packages/create-instantsearch-app/e2e/__snapshots__/templates.test.js.snap +++ b/packages/create-instantsearch-app/e2e/__snapshots__/templates.test.js.snap @@ -1,680 +1,5 @@ // Jest Snapshot v1, https://goo.gl/fbAQLP -exports[`Templates Angular InstantSearch File content: .browserslistrc 1`] = ` -"# This file is used by the build system to adjust CSS and JS output to support the specified browsers below. -# For additional information regarding the format and rule options, please see: -# https://github.com/browserslist/browserslist#queries - -# For the full list of supported browsers by the Angular framework, please see: -# https://angular.io/guide/browser-support - -# You can see what browsers were selected by your queries by running: -# npx browserslist - -last 1 Chrome version -last 1 Firefox version -last 2 Edge major versions -last 2 Safari major versions -last 2 iOS major versions -Firefox ESR -not IE 11 # Angular supports IE 11 only as an opt-in. To opt-in, remove the 'not' prefix on this line." -`; - -exports[`Templates Angular InstantSearch File content: .editorconfig 1`] = ` -"# Editor configuration, see https://editorconfig.org -root = true - -[*] -charset = utf-8 -indent_style = space -indent_size = 2 -insert_final_newline = true -trim_trailing_whitespace = true - -[*.ts] -quote_type = single - -[*.md] -max_line_length = off -trim_trailing_whitespace = false" -`; - -exports[`Templates Angular InstantSearch File content: .gitignore 1`] = ` -"node_modules/ -npm-debug.log -yarn-debug.log -yarn-error.log -dist/" -`; - -exports[`Templates Angular InstantSearch File content: README.md 1`] = ` -"# angular-instantsearch-app - -_This project was generated with [create-instantsearch-app](https://github.com/algolia/instantsearch/tree/master/packages/create-instantsearch-app) by [Algolia](https://algolia.com)._ - -## Get started - -To run this project locally, install the dependencies and run the local server: - -\`\`\`sh -npm install -npm start -\`\`\` - -Alternatively, you may use [Yarn](https://http://yarnpkg.com/): - -\`\`\`sh -yarn -yarn start -\`\`\` - -Open http://localhost:3000 to see your app." -`; - -exports[`Templates Angular InstantSearch File content: angular.json 1`] = ` -"{ - \\"$schema\\": \\"./node_modules/@angular/cli/lib/config/schema.json\\", - \\"version\\": 1, - \\"newProjectRoot\\": \\"projects\\", - \\"projects\\": { - \\"angular-instantsearch-app\\": { - \\"projectType\\": \\"application\\", - \\"schematics\\": { - \\"@schematics/angular:application\\": { - \\"strict\\": true - } - }, - \\"root\\": \\"\\", - \\"sourceRoot\\": \\"src\\", - \\"prefix\\": \\"app\\", - \\"architect\\": { - \\"build\\": { - \\"builder\\": \\"@angular-devkit/build-angular:browser\\", - \\"options\\": { - \\"outputPath\\": \\"dist/angular-instantsearch-app\\", - \\"index\\": \\"src/index.html\\", - \\"main\\": \\"src/main.ts\\", - \\"polyfills\\": \\"src/polyfills.ts\\", - \\"tsConfig\\": \\"tsconfig.app.json\\", - \\"assets\\": [\\"src/favicon.ico\\", \\"src/assets\\"], - \\"styles\\": [\\"src/styles.css\\"], - \\"scripts\\": [] - }, - \\"configurations\\": { - \\"production\\": { - \\"budgets\\": [ - { - \\"type\\": \\"initial\\", - \\"maximumWarning\\": \\"500kb\\", - \\"maximumError\\": \\"1mb\\" - }, - { - \\"type\\": \\"anyComponentStyle\\", - \\"maximumWarning\\": \\"2kb\\", - \\"maximumError\\": \\"4kb\\" - } - ], - \\"fileReplacements\\": [ - { - \\"replace\\": \\"src/environments/environment.ts\\", - \\"with\\": \\"src/environments/environment.prod.ts\\" - } - ], - \\"outputHashing\\": \\"all\\" - }, - \\"development\\": { - \\"buildOptimizer\\": false, - \\"optimization\\": false, - \\"vendorChunk\\": true, - \\"extractLicenses\\": false, - \\"sourceMap\\": true, - \\"namedChunks\\": true - } - }, - \\"defaultConfiguration\\": \\"production\\" - }, - \\"serve\\": { - \\"builder\\": \\"@angular-devkit/build-angular:dev-server\\", - \\"configurations\\": { - \\"production\\": { - \\"browserTarget\\": \\"angular-instantsearch-app:build:production\\" - }, - \\"development\\": { - \\"browserTarget\\": \\"angular-instantsearch-app:build:development\\" - } - }, - \\"defaultConfiguration\\": \\"development\\" - }, - \\"extract-i18n\\": { - \\"builder\\": \\"@angular-devkit/build-angular:extract-i18n\\", - \\"options\\": { - \\"browserTarget\\": \\"angular-instantsearch-app:build\\" - } - }, - \\"test\\": { - \\"builder\\": \\"@angular-devkit/build-angular:karma\\", - \\"options\\": { - \\"main\\": \\"src/test.ts\\", - \\"polyfills\\": \\"src/polyfills.ts\\", - \\"tsConfig\\": \\"tsconfig.spec.json\\", - \\"karmaConfig\\": \\"karma.conf.js\\", - \\"assets\\": [\\"src/favicon.ico\\", \\"src/assets\\"], - \\"styles\\": [ - \\"node_modules/instantsearch.css/themes/satellite.css\\", - \\"src/styles.css\\" - ], - \\"scripts\\": [] - } - } - } - } - }, - \\"defaultProject\\": \\"angular-instantsearch-app\\" -}" -`; - -exports[`Templates Angular InstantSearch File content: karma.conf.js 1`] = ` -"// Karma configuration file, see link for more information -// https://karma-runner.github.io/1.0/config/configuration-file.html - -module.exports = function (config) { - config.set({ - basePath: '', - frameworks: ['jasmine', '@angular-devkit/build-angular'], - plugins: [ - require('karma-jasmine'), - require('karma-chrome-launcher'), - require('karma-jasmine-html-reporter'), - require('karma-coverage'), - require('@angular-devkit/build-angular/plugins/karma'), - ], - client: { - jasmine: { - // you can add configuration options for Jasmine here - // the possible options are listed at https://jasmine.github.io/api/edge/Configuration.html - // for example, you can disable the random execution with \`random: false\` - // or set a specific seed with \`seed: 4321\` - }, - clearContext: false, // leave Jasmine Spec Runner output visible in browser - }, - jasmineHtmlReporter: { - suppressAll: true, // removes the duplicated traces - }, - coverageReporter: { - dir: require('path').join(__dirname, './coverage/angular-instantsearch-app'), - subdir: '.', - reporters: [{ type: 'html' }, { type: 'text-summary' }], - }, - reporters: ['progress', 'kjhtml'], - port: 9876, - colors: true, - logLevel: config.LOG_INFO, - autoWatch: true, - browsers: ['Chrome'], - singleRun: false, - restartOnFileChange: true, - }); -};" -`; - -exports[`Templates Angular InstantSearch File content: package.json 1`] = ` -"{ - \\"name\\": \\"angular-instantsearch-app\\", - \\"version\\": \\"1.0.0\\", - \\"scripts\\": { - \\"ng\\": \\"ng\\", - \\"start\\": \\"ng serve --port 3000\\", - \\"build\\": \\"ng build\\", - \\"watch\\": \\"ng build --watch --configuration development\\", - \\"test\\": \\"ng test\\" - }, - \\"private\\": true, - \\"partialDependencies\\": { - \\"angular-instantsearch\\": \\"4.0.0\\" - } -}" -`; - -exports[`Templates Angular InstantSearch File content: src/app/app.component.css 1`] = ` -".header { - display: flex; - align-items: center; - min-height: 50px; - padding: 0.5rem 1rem; - background-image: linear-gradient(to right, #c3002f, #dd0031); - color: #fff; - margin-bottom: 1rem; -} - -.header a { - color: #fff; - text-decoration: none; -} - -.header-title { - font-size: 1.2rem; - font-weight: normal; -} - -.header-title::after { - content: ' ▸ '; - padding: 0 0.5rem; -} - -.header-subtitle { - font-size: 1.2rem; -} - -.container { - max-width: 1200px; - margin: 0 auto; - padding: 1rem; -} - -.search-panel { - display: flex; -} - -.search-panel__filters { - flex: 1; -} - -.search-panel__results { - flex: 3; -} - -.searchbox { - margin-bottom: 2rem; -} - -.pagination { - margin: 2rem auto; - text-align: center; -}" -`; - -exports[`Templates Angular InstantSearch File content: src/app/app.component.html 1`] = ` -"

-

- angular-instantsearch-app -

-

- using - - Angular InstantSearch - -

-
- -
- - -
-
- - - - - - -
- -
-
- -
- - - -
- No results found matching . -
- -
    -
  1. -
    -

    - -

    - -

    - -

    -
    -
  2. -
-
-
- -
- -
-
- -
-
-
" -`; - -exports[`Templates Angular InstantSearch File content: src/app/app.component.ts 1`] = ` -"import { Component } from '@angular/core'; -import algoliasearch from 'algoliasearch/lite'; - -const searchClient = algoliasearch('appId', 'apiKey'); - -@Component({ - selector: 'app-root', - templateUrl: './app.component.html', - styleUrls: ['./app.component.css'], -}) -export class AppComponent { - config = { - indexName: 'indexName', - searchClient, - }; -}" -`; - -exports[`Templates Angular InstantSearch File content: src/app/app.module.ts 1`] = ` -"import { BrowserModule } from '@angular/platform-browser'; -import { NgModule } from '@angular/core'; -import { NgAisModule } from 'angular-instantsearch'; - -import { AppComponent } from './app.component'; - -@NgModule({ - declarations: [AppComponent], - imports: [NgAisModule.forRoot(), BrowserModule], - providers: [], - bootstrap: [AppComponent], -}) -export class AppModule {}" -`; - -exports[`Templates Angular InstantSearch File content: src/assets/.gitkeep 1`] = `""`; - -exports[`Templates Angular InstantSearch File content: src/environments/environment.prod.ts 1`] = ` -"export const environment = { - production: true, -};" -`; - -exports[`Templates Angular InstantSearch File content: src/environments/environment.ts 1`] = ` -"// This file can be replaced during build by using the \`fileReplacements\` array. -// \`ng build\` replaces \`environment.ts\` with \`environment.prod.ts\`. -// The list of file replacements can be found in \`angular.json\`. - -export const environment = { - production: false, -}; - -/* - * For easier debugging in development mode, you can import the following file - * to ignore zone related error stack frames such as \`zone.run\`, \`zoneDelegate.invokeTask\`. - * - * This import should be commented out in production mode because it will have a negative impact - * on performance if an error is thrown. - */ -// import 'zone.js/plugins/zone-error'; // Included with Angular CLI." -`; - -exports[`Templates Angular InstantSearch File content: src/index.html 1`] = ` -" - - - - angular-instantsearch-app - - - - - - - - -" -`; - -exports[`Templates Angular InstantSearch File content: src/main.ts 1`] = ` -"import { enableProdMode } from '@angular/core'; -import { platformBrowserDynamic } from '@angular/platform-browser-dynamic'; - -import { AppModule } from './app/app.module'; -import { environment } from './environments/environment'; - -if (environment.production) { - enableProdMode(); -} - -platformBrowserDynamic() - .bootstrapModule(AppModule) - .catch((err) => console.error(err));" -`; - -exports[`Templates Angular InstantSearch File content: src/polyfills.ts 1`] = ` -"/** - * This file includes polyfills needed by Angular and is loaded before the app. - * You can add your own extra polyfills to this file. - * - * This file is divided into 2 sections: - * 1. Browser polyfills. These are applied before loading ZoneJS and are sorted by browsers. - * 2. Application imports. Files imported after ZoneJS that should be loaded before your main - * file. - * - * The current setup is for so-called \\"evergreen\\" browsers; the last versions of browsers that - * automatically update themselves. This includes Safari >= 10, Chrome >= 55 (including Opera), - * Edge >= 13 on the desktop, and iOS 10 and Chrome on mobile. - * - * Learn more in https://angular.io/guide/browser-support - */ - -/*************************************************************************************************** - * BROWSER POLYFILLS - */ - -/** - * IE11 requires the following for NgClass support on SVG elements - */ -// import 'classlist.js'; // Run \`npm install --save classlist.js\`. - -/** - * Web Animations \`@angular/platform-browser/animations\` - * Only required if AnimationBuilder is used within the application and using IE/Edge or Safari. - * Standard animation support in Angular DOES NOT require any polyfills (as of Angular 6.0). - */ -// import 'web-animations-js'; // Run \`npm install --save web-animations-js\`. - -/** - * By default, zone.js will patch all possible macroTask and DomEvents - * user can disable parts of macroTask/DomEvents patch by setting following flags - * because those flags need to be set before \`zone.js\` being loaded, and webpack - * will put import in the top of bundle, so user need to create a separate file - * in this directory (for example: zone-flags.ts), and put the following flags - * into that file, and then add the following code before importing zone.js. - * import './zone-flags'; - * - * The flags allowed in zone-flags.ts are listed here. - * - * The following flags will work for all browsers. - * - * (window as any).__Zone_disable_requestAnimationFrame = true; // disable patch requestAnimationFrame - * (window as any).__Zone_disable_on_property = true; // disable patch onProperty such as onclick - * (window as any).__zone_symbol__UNPATCHED_EVENTS = ['scroll', 'mousemove']; // disable patch specified eventNames - * - * in IE/Edge developer tools, the addEventListener will also be wrapped by zone.js - * with the following flag, it will bypass \`zone.js\` patch for IE/Edge - * - * (window as any).__Zone_enable_cross_context_check = true; - * - */ - -/*************************************************************************************************** - * Zone JS is required by default for Angular itself. - */ -import 'zone.js'; // Included with Angular CLI. - -/*************************************************************************************************** - * APPLICATION IMPORTS - */ - -(window as any).process = { - env: { DEBUG: undefined }, -};" -`; - -exports[`Templates Angular InstantSearch File content: src/styles.css 1`] = ` -"/* You can add global styles to this file, and also import other style files */ -body, -h1 { - margin: 0; - padding: 0; -} - -body { - font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, - Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol'; -}" -`; - -exports[`Templates Angular InstantSearch File content: src/test.ts 1`] = ` -"// This file is required by karma.conf.js and loads recursively all the .spec and framework files - -import 'zone.js/testing'; -import { getTestBed } from '@angular/core/testing'; -import { - BrowserDynamicTestingModule, - platformBrowserDynamicTesting, -} from '@angular/platform-browser-dynamic/testing'; - -declare const require: { - context( - path: string, - deep?: boolean, - filter?: RegExp - ): { - keys(): string[]; - (id: string): T; - }; -}; - -// First, initialize the Angular testing environment. -getTestBed().initTestEnvironment( - BrowserDynamicTestingModule, - platformBrowserDynamicTesting(), - { teardown: { destroyAfterEach: true } } -); - -// Then we find all the tests. -const context = require.context('./', true, /\\\\.spec\\\\.ts$/); -// And load the modules. -context.keys().map(context);" -`; - -exports[`Templates Angular InstantSearch File content: tsconfig.app.json 1`] = ` -"/* To learn more about this file see: https://angular.io/config/tsconfig. */ -{ - \\"extends\\": \\"./tsconfig.json\\", - \\"compilerOptions\\": { - \\"outDir\\": \\"./out-tsc/app\\", - \\"types\\": [] - }, - \\"files\\": [ - \\"src/main.ts\\", - \\"src/polyfills.ts\\" - ], - \\"include\\": [ - \\"src/**/*.d.ts\\" - ] -}" -`; - -exports[`Templates Angular InstantSearch File content: tsconfig.json 1`] = ` -"/* To learn more about this file see: https://angular.io/config/tsconfig. */ -{ - \\"compileOnSave\\": false, - \\"compilerOptions\\": { - \\"baseUrl\\": \\"./\\", - \\"outDir\\": \\"./dist/out-tsc\\", - \\"forceConsistentCasingInFileNames\\": true, - \\"strict\\": true, - \\"noImplicitReturns\\": true, - \\"noFallthroughCasesInSwitch\\": true, - \\"sourceMap\\": true, - \\"declaration\\": false, - \\"downlevelIteration\\": true, - \\"experimentalDecorators\\": true, - \\"moduleResolution\\": \\"node\\", - \\"esModuleInterop\\": true, - \\"importHelpers\\": true, - \\"target\\": \\"es2017\\", - \\"module\\": \\"es2020\\", - \\"lib\\": [ - \\"es2018\\", - \\"dom\\" - ], - \\"allowSyntheticDefaultImports\\": true - }, - \\"angularCompilerOptions\\": { - \\"enableI18nLegacyMessageIdFormat\\": false, - \\"strictInjectionParameters\\": true, - \\"strictInputAccessModifiers\\": true, - \\"strictTemplates\\": true - } -}" -`; - -exports[`Templates Angular InstantSearch File content: tsconfig.spec.json 1`] = ` -"/* To learn more about this file see: https://angular.io/config/tsconfig. */ -{ - \\"extends\\": \\"./tsconfig.json\\", - \\"compilerOptions\\": { - \\"outDir\\": \\"./out-tsc/spec\\", - \\"types\\": [ - \\"jasmine\\" - ] - }, - \\"files\\": [ - \\"src/test.ts\\", - \\"src/polyfills.ts\\" - ], - \\"include\\": [ - \\"src/**/*.spec.ts\\", - \\"src/**/*.d.ts\\" - ] -}" -`; - -exports[`Templates Angular InstantSearch Folder structure: contains the right files 1`] = ` -Array [ - ".browserslistrc", - ".editorconfig", - ".gitignore", - "README.md", - "angular.json", - "karma.conf.js", - "package.json", - "src/app/app.component.css", - "src/app/app.component.html", - "src/app/app.component.ts", - "src/app/app.module.ts", - "src/assets/.gitkeep", - "src/environments/environment.prod.ts", - "src/environments/environment.ts", - "src/favicon.ico", - "src/index.html", - "src/main.ts", - "src/polyfills.ts", - "src/styles.css", - "src/test.ts", - "tsconfig.app.json", - "tsconfig.json", - "tsconfig.spec.json", -] -`; - exports[`Templates Autocomplete File content: .editorconfig 1`] = ` "root = true diff --git a/packages/create-instantsearch-app/src/api/__tests__/__snapshots__/index.test.js.snap b/packages/create-instantsearch-app/src/api/__tests__/__snapshots__/index.test.js.snap index fd64614e2e..3c17da5f29 100644 --- a/packages/create-instantsearch-app/src/api/__tests__/__snapshots__/index.test.js.snap +++ b/packages/create-instantsearch-app/src/api/__tests__/__snapshots__/index.test.js.snap @@ -6,10 +6,10 @@ exports[`Options with invalid name throws 1`] = ` - name can only contain URL-friendly characters" `; -exports[`Options with unknown template throws 1`] = `"The template directory must contain a configuration file \`.template.js\` or must be one of those: Angular InstantSearch, Autocomplete, InstantSearch Android, InstantSearch iOS, InstantSearch.js, InstantSearch.js widget, JavaScript Client, JavaScript Helper, React InstantSearch, React InstantSearch Native, Vue InstantSearch, Vue InstantSearch with Vue 3"`; +exports[`Options with unknown template throws 1`] = `"The template directory must contain a configuration file \`.template.js\` or must be one of those: Autocomplete, InstantSearch Android, InstantSearch iOS, InstantSearch.js, InstantSearch.js widget, JavaScript Client, JavaScript Helper, React InstantSearch, React InstantSearch Native, Vue InstantSearch, Vue InstantSearch with Vue 3"`; -exports[`Options with wrong template path throws 1`] = `"The template directory must contain a configuration file \`.template.js\` or must be one of those: Angular InstantSearch, Autocomplete, InstantSearch Android, InstantSearch iOS, InstantSearch.js, InstantSearch.js widget, JavaScript Client, JavaScript Helper, React InstantSearch, React InstantSearch Native, Vue InstantSearch, Vue InstantSearch with Vue 3"`; +exports[`Options with wrong template path throws 1`] = `"The template directory must contain a configuration file \`.template.js\` or must be one of those: Autocomplete, InstantSearch Android, InstantSearch iOS, InstantSearch.js, InstantSearch.js widget, JavaScript Client, JavaScript Helper, React InstantSearch, React InstantSearch Native, Vue InstantSearch, Vue InstantSearch with Vue 3"`; exports[`Options without path throws 1`] = `"The option \`path\` is required."`; -exports[`Options without template throws 1`] = `"The template directory must contain a configuration file \`.template.js\` or must be one of those: Angular InstantSearch, Autocomplete, InstantSearch Android, InstantSearch iOS, InstantSearch.js, InstantSearch.js widget, JavaScript Client, JavaScript Helper, React InstantSearch, React InstantSearch Native, Vue InstantSearch, Vue InstantSearch with Vue 3"`; +exports[`Options without template throws 1`] = `"The template directory must contain a configuration file \`.template.js\` or must be one of those: Autocomplete, InstantSearch Android, InstantSearch iOS, InstantSearch.js, InstantSearch.js widget, JavaScript Client, JavaScript Helper, React InstantSearch, React InstantSearch Native, Vue InstantSearch, Vue InstantSearch with Vue 3"`; diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/.browserslistrc b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/.browserslistrc deleted file mode 100644 index 427441dc93..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/.browserslistrc +++ /dev/null @@ -1,17 +0,0 @@ -# This file is used by the build system to adjust CSS and JS output to support the specified browsers below. -# For additional information regarding the format and rule options, please see: -# https://github.com/browserslist/browserslist#queries - -# For the full list of supported browsers by the Angular framework, please see: -# https://angular.io/guide/browser-support - -# You can see what browsers were selected by your queries by running: -# npx browserslist - -last 1 Chrome version -last 1 Firefox version -last 2 Edge major versions -last 2 Safari major versions -last 2 iOS major versions -Firefox ESR -not IE 11 # Angular supports IE 11 only as an opt-in. To opt-in, remove the 'not' prefix on this line. diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/.editorconfig b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/.editorconfig deleted file mode 100644 index 59d9a3a3e7..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/.editorconfig +++ /dev/null @@ -1,16 +0,0 @@ -# Editor configuration, see https://editorconfig.org -root = true - -[*] -charset = utf-8 -indent_style = space -indent_size = 2 -insert_final_newline = true -trim_trailing_whitespace = true - -[*.ts] -quote_type = single - -[*.md] -max_line_length = off -trim_trailing_whitespace = false diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/.gitignore.template b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/.gitignore.template deleted file mode 100644 index 77a4e9098d..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/.gitignore.template +++ /dev/null @@ -1,5 +0,0 @@ -node_modules/ -npm-debug.log -yarn-debug.log -yarn-error.log -dist/ diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/.template.js b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/.template.js deleted file mode 100644 index f3ddb264d0..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/.template.js +++ /dev/null @@ -1,15 +0,0 @@ -const install = require('../../tasks/node/install'); -const teardown = require('../../tasks/node/teardown'); - -module.exports = { - category: 'Web', - libraryName: 'angular-instantsearch', - templateName: 'angular-instantsearch', - supportedVersion: '^4.0.0', - appName: 'angular-instantsearch-app', - keywords: ['algolia', 'InstantSearch', 'Angular', 'angular-instantsearch'], - tasks: { - install, - teardown, - }, -}; diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/README.md b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/README.md deleted file mode 100644 index 9dae53295f..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/README.md +++ /dev/null @@ -1,21 +0,0 @@ -# {{name}} - -_This project was generated with [create-instantsearch-app](https://github.com/algolia/instantsearch/tree/master/packages/create-instantsearch-app) by [Algolia](https://algolia.com)._ - -## Get started - -To run this project locally, install the dependencies and run the local server: - -```sh -npm install -npm start -``` - -Alternatively, you may use [Yarn](https://http://yarnpkg.com/): - -```sh -yarn -yarn start -``` - -Open http://localhost:3000 to see your app. diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/angular.json b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/angular.json deleted file mode 100644 index 0383107620..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/angular.json +++ /dev/null @@ -1,99 +0,0 @@ -{ - "$schema": "./node_modules/@angular/cli/lib/config/schema.json", - "version": 1, - "newProjectRoot": "projects", - "projects": { - "{{name}}": { - "projectType": "application", - "schematics": { - "@schematics/angular:application": { - "strict": true - } - }, - "root": "", - "sourceRoot": "src", - "prefix": "app", - "architect": { - "build": { - "builder": "@angular-devkit/build-angular:browser", - "options": { - "outputPath": "dist/{{name}}", - "index": "src/index.html", - "main": "src/main.ts", - "polyfills": "src/polyfills.ts", - "tsConfig": "tsconfig.app.json", - "assets": ["src/favicon.ico", "src/assets"], - "styles": ["src/styles.css"], - "scripts": [] - }, - "configurations": { - "production": { - "budgets": [ - { - "type": "initial", - "maximumWarning": "500kb", - "maximumError": "1mb" - }, - { - "type": "anyComponentStyle", - "maximumWarning": "2kb", - "maximumError": "4kb" - } - ], - "fileReplacements": [ - { - "replace": "src/environments/environment.ts", - "with": "src/environments/environment.prod.ts" - } - ], - "outputHashing": "all" - }, - "development": { - "buildOptimizer": false, - "optimization": false, - "vendorChunk": true, - "extractLicenses": false, - "sourceMap": true, - "namedChunks": true - } - }, - "defaultConfiguration": "production" - }, - "serve": { - "builder": "@angular-devkit/build-angular:dev-server", - "configurations": { - "production": { - "browserTarget": "{{name}}:build:production" - }, - "development": { - "browserTarget": "{{name}}:build:development" - } - }, - "defaultConfiguration": "development" - }, - "extract-i18n": { - "builder": "@angular-devkit/build-angular:extract-i18n", - "options": { - "browserTarget": "{{name}}:build" - } - }, - "test": { - "builder": "@angular-devkit/build-angular:karma", - "options": { - "main": "src/test.ts", - "polyfills": "src/polyfills.ts", - "tsConfig": "tsconfig.spec.json", - "karmaConfig": "karma.conf.js", - "assets": ["src/favicon.ico", "src/assets"], - "styles": [ - "node_modules/instantsearch.css/themes/satellite.css", - "src/styles.css" - ], - "scripts": [] - } - } - } - } - }, - "defaultProject": "{{name}}" -} diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/karma.conf.js b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/karma.conf.js deleted file mode 100644 index 3b1ab67d83..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/karma.conf.js +++ /dev/null @@ -1,41 +0,0 @@ -// Karma configuration file, see link for more information -// https://karma-runner.github.io/1.0/config/configuration-file.html - -module.exports = function (config) { - config.set({ - basePath: '', - frameworks: ['jasmine', '@angular-devkit/build-angular'], - plugins: [ - require('karma-jasmine'), - require('karma-chrome-launcher'), - require('karma-jasmine-html-reporter'), - require('karma-coverage'), - require('@angular-devkit/build-angular/plugins/karma'), - ], - client: { - jasmine: { - // you can add configuration options for Jasmine here - // the possible options are listed at https://jasmine.github.io/api/edge/Configuration.html - // for example, you can disable the random execution with `random: false` - // or set a specific seed with `seed: 4321` - }, - clearContext: false, // leave Jasmine Spec Runner output visible in browser - }, - jasmineHtmlReporter: { - suppressAll: true, // removes the duplicated traces - }, - coverageReporter: { - dir: require('path').join(__dirname, './coverage/{{name}}'), - subdir: '.', - reporters: [{ type: 'html' }, { type: 'text-summary' }], - }, - reporters: ['progress', 'kjhtml'], - port: 9876, - colors: true, - logLevel: config.LOG_INFO, - autoWatch: true, - browsers: ['Chrome'], - singleRun: false, - restartOnFileChange: true, - }); -}; diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/package.json b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/package.json deleted file mode 100644 index fd045dd893..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/package.json +++ /dev/null @@ -1,41 +0,0 @@ -{ - "name": "{{name}}", - "version": "1.0.0", - "scripts": { - "ng": "ng", - "start": "ng serve --port 3000", - "build": "ng build", - "watch": "ng build --watch --configuration development", - "test": "ng test" - }, - "private": true, - "dependencies": { - "@angular/animations": "15.2.10", - "@angular/common": "15.2.10", - "@angular/compiler": "15.2.10", - "@angular/core": "15.2.10", - "@angular/forms": "15.2.10", - "@angular/platform-browser": "15.2.10", - "@angular/platform-browser-dynamic": "15.2.10", - "@angular/router": "15.2.10", - "algoliasearch": "4", - "angular-instantsearch": "{{libraryVersion}}", - "rxjs": "6.6.0", - "tslib": "2.3.0", - "zone.js": "0.11.4" - }, - "devDependencies": { - "@angular-devkit/build-angular": "15.2.10", - "@angular/cli": "15.2.10", - "@angular/compiler-cli": "15.2.10", - "@types/jasmine": "3.8.0", - "@types/node": "12.11.1", - "jasmine-core": "3.8.0", - "karma": "6.3.0", - "karma-chrome-launcher": "3.1.0", - "karma-coverage": "2.0.3", - "karma-jasmine": "4.0.0", - "karma-jasmine-html-reporter": "1.7.0", - "typescript": "4.9.5" - } -} diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/app/app.component.css b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/app/app.component.css deleted file mode 100644 index 4e70ecc506..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/app/app.component.css +++ /dev/null @@ -1,55 +0,0 @@ -.header { - display: flex; - align-items: center; - min-height: 50px; - padding: 0.5rem 1rem; - background-image: linear-gradient(to right, #c3002f, #dd0031); - color: #fff; - margin-bottom: 1rem; -} - -.header a { - color: #fff; - text-decoration: none; -} - -.header-title { - font-size: 1.2rem; - font-weight: normal; -} - -.header-title::after { - content: ' ▸ '; - padding: 0 0.5rem; -} - -.header-subtitle { - font-size: 1.2rem; -} - -.container { - max-width: 1200px; - margin: 0 auto; - padding: 1rem; -} - -.search-panel { - display: flex; -} - -.search-panel__filters { - flex: 1; -} - -.search-panel__results { - flex: 3; -} - -.searchbox { - margin-bottom: 2rem; -} - -.pagination { - margin: 2rem auto; - text-align: center; -} diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/app/app.component.html.hbs b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/app/app.component.html.hbs deleted file mode 100644 index 4ec69e8d4d..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/app/app.component.html.hbs +++ /dev/null @@ -1,69 +0,0 @@ -
-

- {{name}} -

-

- using - - Angular InstantSearch - -

-
- -
- - -
- {{#if attributesForFaceting}} -
- {{#each attributesForFaceting}} - - - - {{/each}} -
- - {{/if}} -
- - - {{#if attributesToDisplay}} - - -
- No results found matching . -
- -
    -
  1. -
    -

    - -

    - - {{#each attributesToDisplay}} - {{#unless @first}} -

    - -

    - {{/unless}} - {{/each}} -
    -
  2. -
-
-
- {{else}} - - {{/if}} - - -
- -
-
-
diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/app/app.component.ts b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/app/app.component.ts deleted file mode 100644 index 339c221903..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/app/app.component.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { Component } from '@angular/core'; -import algoliasearch from 'algoliasearch/lite'; - -const searchClient = algoliasearch('{{appId}}', '{{apiKey}}'); - -@Component({ - selector: 'app-root', - templateUrl: './app.component.html', - styleUrls: ['./app.component.css'], -}) -export class AppComponent { - config = { - indexName: '{{indexName}}', - searchClient, - }; -} diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/app/app.module.ts b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/app/app.module.ts deleted file mode 100644 index 7320476bec..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/app/app.module.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { BrowserModule } from '@angular/platform-browser'; -import { NgModule } from '@angular/core'; -import { NgAisModule } from 'angular-instantsearch'; - -import { AppComponent } from './app.component'; - -@NgModule({ - declarations: [AppComponent], - imports: [NgAisModule.forRoot(), BrowserModule], - providers: [], - bootstrap: [AppComponent], -}) -export class AppModule {} diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/assets/.gitkeep b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/assets/.gitkeep deleted file mode 100644 index e69de29bb2..0000000000 diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/environments/environment.prod.ts b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/environments/environment.prod.ts deleted file mode 100644 index c9669790be..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/environments/environment.prod.ts +++ /dev/null @@ -1,3 +0,0 @@ -export const environment = { - production: true, -}; diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/environments/environment.ts b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/environments/environment.ts deleted file mode 100644 index 66998ae9a7..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/environments/environment.ts +++ /dev/null @@ -1,16 +0,0 @@ -// This file can be replaced during build by using the `fileReplacements` array. -// `ng build` replaces `environment.ts` with `environment.prod.ts`. -// The list of file replacements can be found in `angular.json`. - -export const environment = { - production: false, -}; - -/* - * For easier debugging in development mode, you can import the following file - * to ignore zone related error stack frames such as `zone.run`, `zoneDelegate.invokeTask`. - * - * This import should be commented out in production mode because it will have a negative impact - * on performance if an error is thrown. - */ -// import 'zone.js/plugins/zone-error'; // Included with Angular CLI. diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/favicon.ico b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/favicon.ico deleted file mode 100644 index 997406ad22..0000000000 Binary files a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/favicon.ico and /dev/null differ diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/index.html b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/index.html deleted file mode 100644 index 7fd383d711..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/index.html +++ /dev/null @@ -1,17 +0,0 @@ - - - - - {{name}} - - - - - - - - - diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/main.ts b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/main.ts deleted file mode 100644 index d9a2e7e4a5..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/main.ts +++ /dev/null @@ -1,13 +0,0 @@ -import { enableProdMode } from '@angular/core'; -import { platformBrowserDynamic } from '@angular/platform-browser-dynamic'; - -import { AppModule } from './app/app.module'; -import { environment } from './environments/environment'; - -if (environment.production) { - enableProdMode(); -} - -platformBrowserDynamic() - .bootstrapModule(AppModule) - .catch((err) => console.error(err)); diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/polyfills.ts b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/polyfills.ts deleted file mode 100644 index d7935d9e63..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/polyfills.ts +++ /dev/null @@ -1,68 +0,0 @@ -/** - * This file includes polyfills needed by Angular and is loaded before the app. - * You can add your own extra polyfills to this file. - * - * This file is divided into 2 sections: - * 1. Browser polyfills. These are applied before loading ZoneJS and are sorted by browsers. - * 2. Application imports. Files imported after ZoneJS that should be loaded before your main - * file. - * - * The current setup is for so-called "evergreen" browsers; the last versions of browsers that - * automatically update themselves. This includes Safari >= 10, Chrome >= 55 (including Opera), - * Edge >= 13 on the desktop, and iOS 10 and Chrome on mobile. - * - * Learn more in https://angular.io/guide/browser-support - */ - -/*************************************************************************************************** - * BROWSER POLYFILLS - */ - -/** - * IE11 requires the following for NgClass support on SVG elements - */ -// import 'classlist.js'; // Run `npm install --save classlist.js`. - -/** - * Web Animations `@angular/platform-browser/animations` - * Only required if AnimationBuilder is used within the application and using IE/Edge or Safari. - * Standard animation support in Angular DOES NOT require any polyfills (as of Angular 6.0). - */ -// import 'web-animations-js'; // Run `npm install --save web-animations-js`. - -/** - * By default, zone.js will patch all possible macroTask and DomEvents - * user can disable parts of macroTask/DomEvents patch by setting following flags - * because those flags need to be set before `zone.js` being loaded, and webpack - * will put import in the top of bundle, so user need to create a separate file - * in this directory (for example: zone-flags.ts), and put the following flags - * into that file, and then add the following code before importing zone.js. - * import './zone-flags'; - * - * The flags allowed in zone-flags.ts are listed here. - * - * The following flags will work for all browsers. - * - * (window as any).__Zone_disable_requestAnimationFrame = true; // disable patch requestAnimationFrame - * (window as any).__Zone_disable_on_property = true; // disable patch onProperty such as onclick - * (window as any).__zone_symbol__UNPATCHED_EVENTS = ['scroll', 'mousemove']; // disable patch specified eventNames - * - * in IE/Edge developer tools, the addEventListener will also be wrapped by zone.js - * with the following flag, it will bypass `zone.js` patch for IE/Edge - * - * (window as any).__Zone_enable_cross_context_check = true; - * - */ - -/*************************************************************************************************** - * Zone JS is required by default for Angular itself. - */ -import 'zone.js'; // Included with Angular CLI. - -/*************************************************************************************************** - * APPLICATION IMPORTS - */ - -(window as any).process = { - env: { DEBUG: undefined }, -}; diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/styles.css b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/styles.css deleted file mode 100644 index 59b9e37359..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/styles.css +++ /dev/null @@ -1,11 +0,0 @@ -/* You can add global styles to this file, and also import other style files */ -body, -h1 { - margin: 0; - padding: 0; -} - -body { - font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, - Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol'; -} diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/test.ts b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/test.ts deleted file mode 100644 index 6969a3e7a7..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/src/test.ts +++ /dev/null @@ -1,31 +0,0 @@ -// This file is required by karma.conf.js and loads recursively all the .spec and framework files - -import 'zone.js/testing'; -import { getTestBed } from '@angular/core/testing'; -import { - BrowserDynamicTestingModule, - platformBrowserDynamicTesting, -} from '@angular/platform-browser-dynamic/testing'; - -declare const require: { - context( - path: string, - deep?: boolean, - filter?: RegExp - ): { - keys(): string[]; - (id: string): T; - }; -}; - -// First, initialize the Angular testing environment. -getTestBed().initTestEnvironment( - BrowserDynamicTestingModule, - platformBrowserDynamicTesting(), - { teardown: { destroyAfterEach: true } } -); - -// Then we find all the tests. -const context = require.context('./', true, /\.spec\.ts$/); -// And load the modules. -context.keys().map(context); diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/tsconfig.app.json b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/tsconfig.app.json deleted file mode 100644 index 82d91dc4a4..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/tsconfig.app.json +++ /dev/null @@ -1,15 +0,0 @@ -/* To learn more about this file see: https://angular.io/config/tsconfig. */ -{ - "extends": "./tsconfig.json", - "compilerOptions": { - "outDir": "./out-tsc/app", - "types": [] - }, - "files": [ - "src/main.ts", - "src/polyfills.ts" - ], - "include": [ - "src/**/*.d.ts" - ] -} diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/tsconfig.json b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/tsconfig.json deleted file mode 100644 index d331b1b5a4..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/tsconfig.json +++ /dev/null @@ -1,32 +0,0 @@ -/* To learn more about this file see: https://angular.io/config/tsconfig. */ -{ - "compileOnSave": false, - "compilerOptions": { - "baseUrl": "./", - "outDir": "./dist/out-tsc", - "forceConsistentCasingInFileNames": true, - "strict": true, - "noImplicitReturns": true, - "noFallthroughCasesInSwitch": true, - "sourceMap": true, - "declaration": false, - "downlevelIteration": true, - "experimentalDecorators": true, - "moduleResolution": "node", - "esModuleInterop": true, - "importHelpers": true, - "target": "es2017", - "module": "es2020", - "lib": [ - "es2018", - "dom" - ], - "allowSyntheticDefaultImports": true - }, - "angularCompilerOptions": { - "enableI18nLegacyMessageIdFormat": false, - "strictInjectionParameters": true, - "strictInputAccessModifiers": true, - "strictTemplates": true - } -} diff --git a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/tsconfig.spec.json b/packages/create-instantsearch-app/src/templates/Angular InstantSearch/tsconfig.spec.json deleted file mode 100644 index 092345b02e..0000000000 --- a/packages/create-instantsearch-app/src/templates/Angular InstantSearch/tsconfig.spec.json +++ /dev/null @@ -1,18 +0,0 @@ -/* To learn more about this file see: https://angular.io/config/tsconfig. */ -{ - "extends": "./tsconfig.json", - "compilerOptions": { - "outDir": "./out-tsc/spec", - "types": [ - "jasmine" - ] - }, - "files": [ - "src/test.ts", - "src/polyfills.ts" - ], - "include": [ - "src/**/*.spec.ts", - "src/**/*.d.ts" - ] -} diff --git a/packages/create-instantsearch-app/src/utils/__tests__/index.test.js b/packages/create-instantsearch-app/src/utils/__tests__/index.test.js index ca355a96db..6c58f7c6be 100644 --- a/packages/create-instantsearch-app/src/utils/__tests__/index.test.js +++ b/packages/create-instantsearch-app/src/utils/__tests__/index.test.js @@ -121,7 +121,6 @@ describe('getTemplatesByCategory', () => { beforeAll(() => { mockReaddirSync.mockImplementation(() => [ 'InstantSearch.js', - 'Angular InstantSearch', 'React InstantSearch', 'Vue InstantSearch', 'React InstantSearch Native', @@ -135,7 +134,6 @@ describe('getTemplatesByCategory', () => { expect(utils.getTemplatesByCategory()).toEqual({ Web: expect.arrayContaining([ 'InstantSearch.js', - 'Angular InstantSearch', 'React InstantSearch', 'Vue InstantSearch', ]), diff --git a/packages/instantsearch.css/README.md b/packages/instantsearch.css/README.md index 44655d6dec..85570b5b75 100644 --- a/packages/instantsearch.css/README.md +++ b/packages/instantsearch.css/README.md @@ -38,7 +38,6 @@ To learn more about the library, follow the guide on how to style your InstantSe - [InstantSearch.js](https://www.algolia.com/doc/guides/building-search-ui/widgets/customize-an-existing-widget/js/#style-your-widgets) - [React InstantSearch](https://www.algolia.com/doc/guides/building-search-ui/widgets/customize-an-existing-widget/react/#style-your-widgets) - [Vue InstantSearch](https://www.algolia.com/doc/guides/building-search-ui/widgets/customize-an-existing-widget/vue/#style-your-widgets) -- [Angular InstantSearch](https://www.algolia.com/doc/guides/building-search-ui/widgets/customize-an-existing-widget/angular/#style-your-widgets) ## Installation @@ -67,12 +66,11 @@ We support the **last two versions of major browsers** (Chrome, Edge, Firefox, S InstantSearch.css is a living standard. This table tracks down the version implemented in each InstantSearch flavor. -| Project | Version | -| --------------------- | ------- | -| InstantSearch.js | 7 | -| React InstantSearch | 7 | -| Vue InstantSearch | 7 | -| Angular InstantSearch | 7 | +| Project | Version | +| ------------------- | ------- | +| InstantSearch.js | 7 | +| React InstantSearch | 7 | +| Vue InstantSearch | 7 | ## Contributing diff --git a/packages/instantsearch.js/README.md b/packages/instantsearch.js/README.md index 11ed00b649..955590c5a3 100644 --- a/packages/instantsearch.js/README.md +++ b/packages/instantsearch.js/README.md @@ -12,7 +12,7 @@ InstantSearch.js is a vanilla JavaScript library that lets you create an instant-search result experience using [Algolia][algolia-website]’s search API. It is part of the InstantSearch family: -**InstantSearch.js** | [React InstantSearch][instantsearch-github] | [Vue InstantSearch][instantsearch-github] | [Angular InstantSearch][instantsearch-angular-github] | [React InstantSearch Native][instantsearch-github] | [InstantSearch Android][instantsearch-android-github] | [InstantSearch iOS][instantsearch-ios-github] +**InstantSearch.js** | [React InstantSearch][instantsearch-github] | [Vue InstantSearch][instantsearch-github] | [React InstantSearch Native][instantsearch-github] | [InstantSearch Android][instantsearch-android-github] | [InstantSearch iOS][instantsearch-ios-github]
Table of contents @@ -181,7 +181,6 @@ InstantSearch.js is [MIT licensed][license-url]. [instantsearch-github]: https://github.com/algolia/instantsearch/ [instantsearch-android-github]: https://github.com/algolia/instantsearch-android [instantsearch-ios-github]: https://github.com/algolia/instantsearch-ios -[instantsearch-angular-github]: https://github.com/algolia/angular-instantsearch [contributing-bugreport]: https://github.com/algolia/instantsearch/issues/new?template=BUG_REPORT.yml&labels=triage,Library%3A%20InstantSearch.js [contributing-featurerequest]: https://github.com/algolia/instantsearch/discussions/new?category=ideas&labels=triage,Library%3A%20InstantSearch.js&title=Feature%20request%3A%20 [contributing-newissue]: https://github.com/algolia/instantsearch/issues/new?labels=triage,Library%3A%20InstantSearch.js diff --git a/packages/instantsearch.js/src/helpers/highlight.ts b/packages/instantsearch.js/src/helpers/highlight.ts index feb207e77e..825af6ab21 100644 --- a/packages/instantsearch.js/src/helpers/highlight.ts +++ b/packages/instantsearch.js/src/helpers/highlight.ts @@ -48,7 +48,7 @@ See: https://alg.li/highlighting const { value: attributeValue = '' } = highlightAttributeResult || {}; - // cx is not used, since it would be bundled as a dependency for Vue & Angular + // cx is not used, since it would be bundled as a dependency for Vue const className = suit({ descendantName: 'highlighted', diff --git a/packages/instantsearch.js/src/helpers/reverseHighlight.ts b/packages/instantsearch.js/src/helpers/reverseHighlight.ts index 0cfca7ec7e..371151c10e 100644 --- a/packages/instantsearch.js/src/helpers/reverseHighlight.ts +++ b/packages/instantsearch.js/src/helpers/reverseHighlight.ts @@ -55,7 +55,7 @@ See: https://alg.li/highlighting const { value: attributeValue = '' } = highlightAttributeResult || {}; - // cx is not used, since it would be bundled as a dependency for Vue & Angular + // cx is not used, since it would be bundled as a dependency for Vue const className = suit({ descendantName: 'highlighted', diff --git a/packages/instantsearch.js/src/helpers/reverseSnippet.ts b/packages/instantsearch.js/src/helpers/reverseSnippet.ts index 404e772348..d2d420b95f 100644 --- a/packages/instantsearch.js/src/helpers/reverseSnippet.ts +++ b/packages/instantsearch.js/src/helpers/reverseSnippet.ts @@ -55,7 +55,7 @@ See: https://alg.li/highlighting const { value: attributeValue = '' } = snippetAttributeResult || {}; - // cx is not used, since it would be bundled as a dependency for Vue & Angular + // cx is not used, since it would be bundled as a dependency for Vue const className = suit({ descendantName: 'highlighted', diff --git a/packages/instantsearch.js/src/helpers/snippet.ts b/packages/instantsearch.js/src/helpers/snippet.ts index 8639cb9224..055165252a 100644 --- a/packages/instantsearch.js/src/helpers/snippet.ts +++ b/packages/instantsearch.js/src/helpers/snippet.ts @@ -48,7 +48,7 @@ See: https://alg.li/highlighting const { value: attributeValue = '' } = snippetAttributeResult || {}; - // cx is not used, since it would be bundled as a dependency for Vue & Angular + // cx is not used, since it would be bundled as a dependency for Vue const className = suit({ descendantName: 'highlighted', diff --git a/packages/react-instantsearch/README.md b/packages/react-instantsearch/README.md index 6b5d70d3ea..13a3a1c27c 100644 --- a/packages/react-instantsearch/README.md +++ b/packages/react-instantsearch/README.md @@ -22,7 +22,7 @@ React InstantSearch is an open-source React library that lets you create an instant search result experience using [Algolia][algolia-website]’s search API. It is part of the InstantSearch family: -**React InstantSearch** | [InstantSearch.js][instantsearch-github] | [Angular InstantSearch][instantsearch-angular-github] | [Vue InstantSearch][instantsearch-github] | [InstantSearch Android][instantsearch-android-github] | [InstantSearch iOS][instantsearch-ios-github] +**React InstantSearch** | [InstantSearch.js][instantsearch-github] | [Vue InstantSearch][instantsearch-github] | [InstantSearch Android][instantsearch-android-github] | [InstantSearch iOS][instantsearch-ios-github] ## Why @@ -116,7 +116,6 @@ React InstantSearch is [MIT licensed](../../LICENSE). [instantsearch-github]: https://github.com/algolia/instantsearch [instantsearch-android-github]: https://github.com/algolia/instantsearch-android [instantsearch-ios-github]: https://github.com/algolia/instantsearch-ios -[instantsearch-angular-github]: https://github.com/algolia/angular-instantsearch [contributing-bugreport]: https://github.com/algolia/instantsearch/issues/new?template=BUG_REPORT.yml&labels=triage,Library%3A%20React+InstantSearch [contributing-featurerequest]: https://github.com/algolia/instantsearch/discussions/new?category=ideas&labels=triage,Library%3A%20React+InstantSearch&title=Feature%20request%3A%20 [contributing-newissue]: https://github.com/algolia/instantsearch/issues/new?labels=triage,Library%3A%20React+InstantSearch diff --git a/packages/vue-instantsearch/README.md b/packages/vue-instantsearch/README.md index 56b75ec05c..c5e8845528 100644 --- a/packages/vue-instantsearch/README.md +++ b/packages/vue-instantsearch/README.md @@ -11,7 +11,7 @@ [![Vue InstantSearch logo][logo]][website] -InstantSearch projects: **Vue InstantSearch** | [InstantSearch.js][instantsearch-github] | [React InstantSearch][instantsearch-github] | [Angular InstantSearch][angular-instantsearch-github] | [InstantSearch Android][instantsearch-android-github] | [InstantSearch iOS][instantsearch-ios-github]. +InstantSearch projects: **Vue InstantSearch** | [InstantSearch.js][instantsearch-github] | [React InstantSearch][instantsearch-github] | [InstantSearch Android][instantsearch-android-github] | [InstantSearch iOS][instantsearch-ios-github]. ## Vue InstantSearch @@ -54,4 +54,3 @@ We welcome all contributors, from casual to regular. You are only one command aw [instantsearch-github]: https://github.com/algolia/instantsearch [instantsearch-android-github]: https://github.com/algolia/instantsearch-android [instantsearch-ios-github]: https://github.com/algolia/instantsearch-ios -[angular-instantsearch-github]: https://github.com/algolia/angular-instantsearch