create-instantsearch-app 6.4.1 → 7.0.0
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/README.md +4 -5
- package/package.json +3 -2
- package/src/api/__tests__/__snapshots__/index.test.js.snap +4 -4
- package/src/api/__tests__/resolve-template.test.js +0 -28
- package/src/api/resolve-template.js +1 -28
- package/src/templates/React InstantSearch/.editorconfig +0 -1
- package/src/templates/React InstantSearch/.gitignore.template +20 -18
- package/src/templates/React InstantSearch/.template.js +4 -3
- package/src/templates/React InstantSearch/README.md +0 -2
- package/src/templates/React InstantSearch/package.json +8 -21
- package/src/templates/React InstantSearch/src/App.css +11 -0
- package/src/templates/{React InstantSearch Hooks → React InstantSearch}/src/App.tsx.hbs +3 -3
- package/src/templates/React InstantSearch Native/.gitignore.template +13 -16
- package/src/templates/React InstantSearch Native/.template.js +2 -1
- package/src/templates/{React InstantSearch Hooks Native → React InstantSearch Native}/App.tsx.hbs +1 -1
- package/src/templates/React InstantSearch Native/app.json +24 -1
- package/src/templates/React InstantSearch Native/package.json +14 -16
- package/src/templates/{React InstantSearch Hooks Native → React InstantSearch Native}/src/InfiniteHits.tsx +1 -1
- package/src/templates/{React InstantSearch Hooks Native → React InstantSearch Native}/src/SearchBox.tsx.hbs +1 -1
- package/src/utils/__tests__/fetchLibraryVersions.test.js +24 -0
- package/src/utils/__tests__/index.test.js +8 -5
- package/src/utils/fetchLibraryVersions.js +37 -0
- package/src/utils/index.js +1 -18
- package/src/templates/Autocomplete.js 0/.editorconfig +0 -9
- package/src/templates/Autocomplete.js 0/.eslintignore +0 -3
- package/src/templates/Autocomplete.js 0/.eslintrc.js +0 -3
- package/src/templates/Autocomplete.js 0/.gitignore.template +0 -22
- package/src/templates/Autocomplete.js 0/.prettierrc +0 -5
- package/src/templates/Autocomplete.js 0/.template.js +0 -13
- package/src/templates/Autocomplete.js 0/README.md +0 -21
- package/src/templates/Autocomplete.js 0/favicon.png +0 -0
- package/src/templates/Autocomplete.js 0/index.html.hbs +0 -46
- package/src/templates/Autocomplete.js 0/manifest.webmanifest +0 -15
- package/src/templates/Autocomplete.js 0/package.json +0 -26
- package/src/templates/Autocomplete.js 0/src/app.css +0 -85
- package/src/templates/Autocomplete.js 0/src/app.js.hbs +0 -31
- package/src/templates/Autocomplete.js 0/src/index.css +0 -7
- package/src/templates/InstantSearch.js 2/.editorconfig +0 -9
- package/src/templates/InstantSearch.js 2/.eslintignore +0 -3
- package/src/templates/InstantSearch.js 2/.eslintrc.js +0 -3
- package/src/templates/InstantSearch.js 2/.gitignore.template +0 -22
- package/src/templates/InstantSearch.js 2/.prettierrc +0 -5
- package/src/templates/InstantSearch.js 2/.template.js +0 -14
- package/src/templates/InstantSearch.js 2/README.md +0 -21
- package/src/templates/InstantSearch.js 2/favicon.png +0 -0
- package/src/templates/InstantSearch.js 2/index.html.hbs +0 -56
- package/src/templates/InstantSearch.js 2/manifest.webmanifest +0 -15
- package/src/templates/InstantSearch.js 2/package.json +0 -22
- package/src/templates/InstantSearch.js 2/src/app.css +0 -75
- package/src/templates/InstantSearch.js 2/src/app.js.hbs +0 -54
- package/src/templates/InstantSearch.js 2/src/index.css +0 -10
- package/src/templates/JavaScript Helper 2/.editorconfig +0 -9
- package/src/templates/JavaScript Helper 2/.eslintignore +0 -3
- package/src/templates/JavaScript Helper 2/.eslintrc.js +0 -3
- package/src/templates/JavaScript Helper 2/.gitignore.template +0 -22
- package/src/templates/JavaScript Helper 2/.prettierrc +0 -5
- package/src/templates/JavaScript Helper 2/.template.js +0 -14
- package/src/templates/JavaScript Helper 2/README.md +0 -21
- package/src/templates/JavaScript Helper 2/favicon.png +0 -0
- package/src/templates/JavaScript Helper 2/index.html.hbs +0 -42
- package/src/templates/JavaScript Helper 2/manifest.webmanifest +0 -15
- package/src/templates/JavaScript Helper 2/package.json +0 -26
- package/src/templates/JavaScript Helper 2/src/app.css +0 -74
- package/src/templates/JavaScript Helper 2/src/app.js.hbs +0 -44
- package/src/templates/JavaScript Helper 2/src/index.css +0 -10
- package/src/templates/React InstantSearch/.eslintrc.js +0 -3
- package/src/templates/React InstantSearch/public/favicon.png +0 -0
- package/src/templates/React InstantSearch/public/index.html +0 -29
- package/src/templates/React InstantSearch/public/manifest.json +0 -15
- package/src/templates/React InstantSearch/src/App.js.hbs +0 -112
- package/src/templates/React InstantSearch/src/index.css +0 -10
- package/src/templates/React InstantSearch/src/index.js +0 -6
- package/src/templates/React InstantSearch Hooks/.editorconfig +0 -8
- package/src/templates/React InstantSearch Hooks/.gitignore.template +0 -23
- package/src/templates/React InstantSearch Hooks/.prettierrc +0 -5
- package/src/templates/React InstantSearch Hooks/.template.js +0 -25
- package/src/templates/React InstantSearch Hooks/README.md +0 -19
- package/src/templates/React InstantSearch Hooks/package.json +0 -21
- package/src/templates/React InstantSearch Hooks/src/App.css +0 -71
- package/src/templates/React InstantSearch Hooks Native/.gitignore.template +0 -14
- package/src/templates/React InstantSearch Hooks Native/.template.js +0 -34
- package/src/templates/React InstantSearch Hooks Native/README.md +0 -19
- package/src/templates/React InstantSearch Hooks Native/app.json +0 -30
- package/src/templates/React InstantSearch Hooks Native/babel.config.js +0 -6
- package/src/templates/React InstantSearch Hooks Native/package.json +0 -30
- package/src/templates/React InstantSearch Native/.editorconfig +0 -9
- package/src/templates/React InstantSearch Native/.eslintrc.js +0 -3
- package/src/templates/React InstantSearch Native/.prettierrc +0 -5
- package/src/templates/React InstantSearch Native/.watchmanconfig +0 -1
- package/src/templates/React InstantSearch Native/App.js.hbs +0 -38
- package/src/templates/React InstantSearch Native/src/Highlight.js +0 -36
- package/src/templates/React InstantSearch Native/src/InfiniteHits.js.hbs +0 -56
- package/src/templates/React InstantSearch Native/src/SearchBox.js.hbs +0 -42
- package/src/templates/React InstantSearch widget/.eslintignore +0 -2
- package/src/templates/React InstantSearch widget/.eslintrc.cjs +0 -13
- package/src/templates/React InstantSearch widget/.prettierrc +0 -5
- package/src/templates/React InstantSearch widget/.template.js +0 -21
- package/src/templates/React InstantSearch widget/CONTRIBUTING.md +0 -49
- package/src/templates/React InstantSearch widget/LICENSE.md.hbs +0 -21
- package/src/templates/React InstantSearch widget/README.md +0 -85
- package/src/templates/React InstantSearch widget/babel.config.cjs +0 -8
- package/src/templates/React InstantSearch widget/example/index.html.hbs +0 -12
- package/src/templates/React InstantSearch widget/example/index.tsx.hbs +0 -22
- package/src/templates/React InstantSearch widget/package.json.hbs +0 -81
- package/src/templates/React InstantSearch widget/src/index.tsx.hbs +0 -3
- package/src/templates/React InstantSearch widget/src/lib/__tests__/dummy-test.tsx.hbs +0 -39
- package/src/templates/React InstantSearch widget/src/lib/component.tsx.hbs +0 -15
- package/src/templates/React InstantSearch widget/src/lib/connector.ts.hbs +0 -35
- package/src/templates/React InstantSearch widget/src/lib/widget.tsx.hbs +0 -14
- package/src/templates/React InstantSearch widget/src/types/connector.ts +0 -17
- package/src/templates/React InstantSearch widget/tsconfig.declaration.json +0 -10
- package/src/templates/React InstantSearch widget/tsconfig.json +0 -20
- package/src/templates/React InstantSearch widget/vite.config.ts +0 -34
- package/src/templates/Vue InstantSearch 1/.editorconfig +0 -9
- package/src/templates/Vue InstantSearch 1/.eslintrc.js +0 -9
- package/src/templates/Vue InstantSearch 1/.gitignore.template +0 -21
- package/src/templates/Vue InstantSearch 1/.prettierrc +0 -5
- package/src/templates/Vue InstantSearch 1/.template.js +0 -14
- package/src/templates/Vue InstantSearch 1/README.md +0 -21
- package/src/templates/Vue InstantSearch 1/babel.config.js +0 -3
- package/src/templates/Vue InstantSearch 1/package.json +0 -35
- package/src/templates/Vue InstantSearch 1/public/favicon.png +0 -0
- package/src/templates/Vue InstantSearch 1/public/index.html +0 -22
- package/src/templates/Vue InstantSearch 1/src/App.vue +0 -167
- package/src/templates/Vue InstantSearch 1/src/main.js +0 -11
- package/src/templates/Vue InstantSearch 2/.editorconfig +0 -9
- package/src/templates/Vue InstantSearch 2/.eslintrc.js +0 -9
- package/src/templates/Vue InstantSearch 2/.gitignore.template +0 -21
- package/src/templates/Vue InstantSearch 2/.prettierrc +0 -5
- package/src/templates/Vue InstantSearch 2/.template.js +0 -15
- package/src/templates/Vue InstantSearch 2/README.md +0 -21
- package/src/templates/Vue InstantSearch 2/babel.config.js +0 -3
- package/src/templates/Vue InstantSearch 2/package.json +0 -37
- package/src/templates/Vue InstantSearch 2/public/favicon.png +0 -0
- package/src/templates/Vue InstantSearch 2/public/index.html +0 -22
- package/src/templates/Vue InstantSearch 2/src/App.vue +0 -147
- package/src/templates/Vue InstantSearch 2/src/main.js +0 -11
- package/src/utils/__tests__/__snapshots__/index.test.js.snap +0 -7
- /package/src/templates/{React InstantSearch Hooks → React InstantSearch}/favicon.png +0 -0
- /package/src/templates/{React InstantSearch Hooks → React InstantSearch}/index.html +0 -0
- /package/src/templates/{React InstantSearch Hooks → React InstantSearch}/src/Panel.tsx +0 -0
- /package/src/templates/{React InstantSearch Hooks → React InstantSearch}/src/index.tsx +0 -0
- /package/src/templates/{React InstantSearch Hooks Native → React InstantSearch Native}/.expo-shared/assets.json +0 -0
- /package/src/templates/{React InstantSearch Hooks Native → React InstantSearch Native}/assets/adaptive-icon.png +0 -0
- /package/src/templates/{React InstantSearch Hooks Native → React InstantSearch Native}/assets/favicon.png +0 -0
- /package/src/templates/{React InstantSearch Hooks Native → React InstantSearch Native}/assets/icon.png +0 -0
- /package/src/templates/{React InstantSearch Hooks Native → React InstantSearch Native}/assets/splash.png +0 -0
- /package/src/templates/{React InstantSearch Hooks Native → React InstantSearch Native}/src/Highlight.tsx +0 -0
- /package/src/templates/{React InstantSearch Hooks Native → React InstantSearch Native}/tsconfig.json +0 -0
- /package/src/templates/{React InstantSearch Hooks Native → React InstantSearch Native}/types/ProductHit.ts +0 -0
|
@@ -1,147 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div>
|
|
3
|
-
<header class="header">
|
|
4
|
-
<h1 class="header-title">
|
|
5
|
-
<a href="/">
|
|
6
|
-
{{name}}
|
|
7
|
-
</a>
|
|
8
|
-
</h1>
|
|
9
|
-
<p class="header-subtitle">
|
|
10
|
-
using
|
|
11
|
-
<a href="https://github.com/algolia/instantsearch/tree/master/packages/vue-instantsearch">
|
|
12
|
-
Vue InstantSearch
|
|
13
|
-
</a>
|
|
14
|
-
</p>
|
|
15
|
-
</header>
|
|
16
|
-
|
|
17
|
-
<div class="container">
|
|
18
|
-
<ais-instant-search :search-client="searchClient" index-name="{{indexName}}">
|
|
19
|
-
<div class="search-panel">
|
|
20
|
-
{{#if attributesForFaceting.length}}
|
|
21
|
-
<div class="search-panel__filters">
|
|
22
|
-
{{#each attributesForFaceting}}
|
|
23
|
-
<ais-refinement-list attribute="{{this}}" />
|
|
24
|
-
{{/each}}
|
|
25
|
-
</div>
|
|
26
|
-
|
|
27
|
-
{{/if}}
|
|
28
|
-
<div class="search-panel__results">
|
|
29
|
-
<div class="searchbox">
|
|
30
|
-
<ais-search-box placeholder="{{searchPlaceholder}}" />
|
|
31
|
-
</div>
|
|
32
|
-
{{#if attributesToDisplay}}
|
|
33
|
-
<ais-hits>
|
|
34
|
-
<template slot="item" slot-scope="{ item }">
|
|
35
|
-
<article>
|
|
36
|
-
<h1>
|
|
37
|
-
<ais-highlight :hit="item" attribute="{{attributesToDisplay.[0]}}" />
|
|
38
|
-
</h1>
|
|
39
|
-
{{#each attributesToDisplay}}
|
|
40
|
-
{{#unless @first}}
|
|
41
|
-
<p>
|
|
42
|
-
<ais-highlight :hit="item" attribute="{{this}}" />
|
|
43
|
-
</p>
|
|
44
|
-
{{/unless}}
|
|
45
|
-
{{/each}}
|
|
46
|
-
</article>
|
|
47
|
-
</template>
|
|
48
|
-
</ais-hits>
|
|
49
|
-
{{else}}
|
|
50
|
-
<ais-hits/>
|
|
51
|
-
{{/if}}
|
|
52
|
-
|
|
53
|
-
<div class="pagination">
|
|
54
|
-
<ais-pagination />
|
|
55
|
-
</div>
|
|
56
|
-
</div>
|
|
57
|
-
</div>
|
|
58
|
-
</ais-instant-search>
|
|
59
|
-
</div>
|
|
60
|
-
</div>
|
|
61
|
-
</template>
|
|
62
|
-
|
|
63
|
-
<script>
|
|
64
|
-
import algoliasearch from 'algoliasearch/lite';
|
|
65
|
-
|
|
66
|
-
export default {
|
|
67
|
-
data() {
|
|
68
|
-
return {
|
|
69
|
-
searchClient: algoliasearch('{{appId}}', '{{apiKey}}'),
|
|
70
|
-
};
|
|
71
|
-
},
|
|
72
|
-
};
|
|
73
|
-
</script>
|
|
74
|
-
|
|
75
|
-
<style>
|
|
76
|
-
body,
|
|
77
|
-
h1 {
|
|
78
|
-
margin: 0;
|
|
79
|
-
padding: 0;
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
body {
|
|
83
|
-
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica,
|
|
84
|
-
Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol';
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
em {
|
|
88
|
-
background: cyan;
|
|
89
|
-
font-style: normal;
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
.header {
|
|
93
|
-
display: flex;
|
|
94
|
-
align-items: center;
|
|
95
|
-
min-height: 50px;
|
|
96
|
-
padding: 0.5rem 1rem;
|
|
97
|
-
background-image: linear-gradient(to right, #4dba87, #2f9088);
|
|
98
|
-
color: #fff;
|
|
99
|
-
margin-bottom: 1rem;
|
|
100
|
-
}
|
|
101
|
-
|
|
102
|
-
.header a {
|
|
103
|
-
color: #fff;
|
|
104
|
-
text-decoration: none;
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
.header-title {
|
|
108
|
-
font-size: 1.2rem;
|
|
109
|
-
font-weight: normal;
|
|
110
|
-
}
|
|
111
|
-
|
|
112
|
-
.header-title::after {
|
|
113
|
-
content: ' ▸ ';
|
|
114
|
-
padding: 0 0.5rem;
|
|
115
|
-
}
|
|
116
|
-
|
|
117
|
-
.header-subtitle {
|
|
118
|
-
font-size: 1.2rem;
|
|
119
|
-
}
|
|
120
|
-
|
|
121
|
-
.container {
|
|
122
|
-
max-width: 1200px;
|
|
123
|
-
margin: 0 auto;
|
|
124
|
-
padding: 1rem;
|
|
125
|
-
}
|
|
126
|
-
|
|
127
|
-
.search-panel {
|
|
128
|
-
display: flex;
|
|
129
|
-
}
|
|
130
|
-
|
|
131
|
-
.search-panel__filters {
|
|
132
|
-
flex: 1;
|
|
133
|
-
}
|
|
134
|
-
|
|
135
|
-
.search-panel__results {
|
|
136
|
-
flex: 3;
|
|
137
|
-
}
|
|
138
|
-
|
|
139
|
-
.searchbox {
|
|
140
|
-
margin-bottom: 2rem;
|
|
141
|
-
}
|
|
142
|
-
|
|
143
|
-
.pagination {
|
|
144
|
-
margin: 2rem auto;
|
|
145
|
-
text-align: center;
|
|
146
|
-
}
|
|
147
|
-
</style>
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
|
-
|
|
3
|
-
exports[`checkAppName throws with correct error message 1`] = `
|
|
4
|
-
"Could not create a project called \\"[31m./project-name[39m\\" because of npm naming restrictions.
|
|
5
|
-
- name cannot start with a period
|
|
6
|
-
- name can only contain URL-friendly characters"
|
|
7
|
-
`;
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/src/templates/{React InstantSearch Hooks Native → React InstantSearch Native}/tsconfig.json
RENAMED
|
File without changes
|
|
File without changes
|