Skip to content

Commit b9bf30f

Browse files
committed
Fix conflict
2 parents b1b78ed + 5705158 commit b9bf30f

File tree

1,004 files changed

+12516
-11930
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,004 files changed

+12516
-11930
lines changed

.editorconfig

100755100644
File mode changed.

.eslintignore

100755100644
File mode changed.

.eslintrc

100755100644
File mode changed.

.gitattributes

100755100644
File mode changed.

.github/ISSUE_TEMPLATE.md

+13-25
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,22 @@
11
<!-- ⚠️ If you do not respect this template your issue will be closed. -->
22

3-
<!-- ISSUE TEMPLATE -->
3+
<!-- =============================================================================== -->
4+
<!-- ⚠️ If you are not using the current Strapi release, you will be asked to update. -->
5+
<!-- Please see the wiki for guides on upgrading to the latest release. -->
6+
<!-- =============================================================================== -->
7+
8+
<!-- ⚠️ Make sure to browse the opened and closed issues before submitting your issue. -->
49

510
<!-- ⚠️ Before writing your issue make sure you are using:-->
6-
<!-- Node 9.x.x -->
7-
<!-- npm 5.x.x -->
8-
<!-- The latest version of Strapi. -->
11+
<!-- Node 10.x.x -->
12+
<!-- npm 6.x.x -->
913

1014
**Informations**
11-
- **Node.js version**:
12-
- **npm version**:
13-
- **Strapi version**:
14-
- **Database**:
15-
- **Operating system**:
15+
- **Node.js version**:
16+
- **npm version**:
17+
- **Strapi version**: <!-- Please make sure you are on the latest version -->
18+
- **Database**:
19+
- **Operating system**:
1620

1721

1822
**What is the current behavior?**
@@ -28,19 +32,3 @@
2832

2933

3034
**Suggested solutions**
31-
32-
33-
34-
<!-- ⚠️ Make sure to browse the opened and closed issues before submitting your issue. -->
35-
36-
37-
38-
<!-- FEATURE REQUEST TEMPLATE -->
39-
40-
<!-- ⚠️ If you do not respect this template your issue will be closed. -->
41-
42-
**What is the expected behavior?**
43-
44-
45-
46-
<!-- ⚠️ Make sure to browse the opened and closed issues before submitting your issue. -->

.github/ISSUE_TEMPLATE/BUG_REPORT.md

+14-11
Original file line numberDiff line numberDiff line change
@@ -5,17 +5,24 @@ about: Create a report to help us improve 🤔.
55

66
<!-- ⚠️ If you do not respect this template your issue will be closed. -->
77

8+
<!-- =============================================================================== -->
9+
<!-- ⚠️ If you are not using the current Strapi release, you will be asked to update. -->
10+
<!-- Please see the wiki for guides on upgrading to the latest release. -->
11+
<!-- =============================================================================== -->
12+
13+
<!-- ⚠️ Make sure to browse the opened and closed issues before submitting your issue. -->
14+
815
<!-- ⚠️ Before writing your issue make sure you are using:-->
9-
<!-- Node 9.x.x -->
10-
<!-- npm 5.x.x -->
16+
<!-- Node 10.x.x -->
17+
<!-- npm 6.x.x -->
1118
<!-- The latest version of Strapi. -->
1219

1320
**Informations**
14-
- **Node.js version**:
15-
- **npm version**:
16-
- **Strapi version**:
17-
- **Database**:
18-
- **Operating system**:
21+
- **Node.js version**:
22+
- **npm version**:
23+
- **Strapi version**: <!-- Please make sure you are on the latest version -->
24+
- **Database**:
25+
- **Operating system**:
1926

2027

2128
**What is the current behavior?**
@@ -31,7 +38,3 @@ about: Create a report to help us improve 🤔.
3138

3239

3340
**Suggested solutions**
34-
35-
36-
37-
<!-- ⚠️ Make sure to browse the opened and closed issues before submitting your issue. -->

.github/ISSUE_TEMPLATE/FEATURE_REQUEST.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ about: Suggest an idea for this project 💡!
55

66
<!-- ⚠️ If you do not respect this template your issue will be closed. -->
77

8-
**What is the expected behavior?**
8+
<!-- ⚠️ Make sure to browse the opened and closed issues before submitting your issue. -->
99

10+
**What is the expected behavior?**
1011

1112

12-
<!-- ⚠️ Make sure to browse the opened and closed issues before submitting your issue. -->

.gitignore

100755100644
File mode changed.

.travis.yml

100755100644
File mode changed.

CONTRIBUTING.md

+7-7
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,11 @@ Every user can send a feature request using the [issues](https://github.com/stra
2121
## Repository Organization
2222
We made the choice to use a monorepo design such as [React](https://github.com/facebook/react/tree/master/packages), [Babel](https://github.com/babel/babel/tree/master/packages), [Meteor](https://github.com/meteor/meteor/tree/devel/packages) or [Ember](https://github.com/emberjs/ember.js/tree/master/packages) do. It allows the community to easily maintain the whole ecosystem up-to-date and consistent.
2323

24-
The Babel team wrotes an excellent short post about [the pros and cons of the monorepo design](https://github.com/babel/babel/blob/master/doc/design/monorepo.md).
24+
The Babel team wrote an excellent short post about [the pros and cons of the monorepo design](https://github.com/babel/babel/blob/master/doc/design/monorepo.md).
2525

26-
We will do our best to keep the master branch clean as possible, with tests passing all the times. However, it can happen that the master branch moves faster than the release cycle. To ensure to use the latest stable version, please refers to the [release on npm](https://www.npmjs.com/package/strapi).
26+
We will do our best to keep the master branch as clean as possible, with tests passing all the times. However, it can happen that the master branch moves faster than the release cycle. To ensure you have the latest stable version, please refer to the [release on npm](https://www.npmjs.com/package/strapi).
2727

28-
If you send a pull request, please do it again the `master` branch. We are developing upcoming versions separately to ensure non-breaking changes from master to the latest stable major version.
28+
If you send a pull request, please do it against the `master` branch. We are developing upcoming versions separately to ensure non-breaking changes from master to the latest stable major version.
2929

3030
***
3131

@@ -38,22 +38,22 @@ Then, please follow the instructions below:
3838

3939
[Go to the repository](https://github.com/strapi/strapi) and fork it to your own GitHub account.
4040

41-
#### 2. 💿 Clone the repository
41+
#### 2. 💿 Clone from your repository
4242

4343
```bash
44-
git clone [email protected]:strapi/strapi.git
44+
git clone [email protected]:YOUR_USERNAME/strapi.git
4545
```
4646

4747
#### 3. ⏳ Installation
48-
48+
4949
Go to the root of the repository.
5050
```bash
5151
cd strapi
5252
```
5353

5454
**Two setup are available... with or without the front-end builds.**
5555

56-
Without the front-end builds, you won't be able to access to the administration panel via http://localhost:1337/admin, you'll have to run the administration separately and access it through http://localhost:4000/admin.
56+
Without the front-end builds, you won't be able to access the administration panel via http://localhost:1337/admin. You'll have to run the administration separately and access it through http://localhost:4000/admin.
5757

5858
<br>
5959

LICENSE.md

100755100644
File mode changed.

Makefile

100755100644
File mode changed.

README.md

100755100644
+8-3
Original file line numberDiff line numberDiff line change
@@ -80,16 +80,21 @@ strapi start
8080

8181
Congratulations, you made it! Enjoy 🎉
8282

83-
<br>
83+
### Try on Heroku
8484

85-
You can also give it a try using Heroku! Be aware that one of the content type builder won't work due to the writing files restriction on the Heroku servers.
85+
You can also give it a try using Heroku in one click!
8686

8787
<a href="https://heroku.com/deploy?template=https://github.com/strapi/strapi-heroku-app">
8888
<img src="https://www.herokucdn.com/deploy/button.svg" alt="Deploy">
8989
</a>
9090

91-
<br>
91+
Be aware that one of the content type builder won't work due to the writing files restriction on the Heroku servers. If you do want to change content types, you need to follow these steps:
9292
93+
1. Click the button above and deploy your app
94+
2. Clone that repo by using `heroku git:clone -a ` followed by your repo's name
95+
3. Go into the cloned projects' folder using `cd` followed by your repo's name
96+
4. Add the Heroku boilerplate as a remote by running `git remote add boilerplate https://github.com/strapi/strapi-heroku-app`
97+
5. Pull from this new origin by running `git pull boilerplate master`
9398

9499
## Features
95100

docs/3.x.x/README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,10 @@ The most advanced open-source Content Management Framework to build powerful API
1212
<!-- {p:.flex.justify-around} -->
1313
:::
1414

15-
## v3@alpha.13 is available!
15+
## v3@alpha.14.2 is available!
1616
We've been working on a major update for Strapi during the past months, rewriting the core framework and the dashboard.
1717

18-
This documentation is only related to Strapi v3@alpha.13 ([v1 documentation is still available](http://strapi.io/documentation/1.x.x)).
18+
This documentation is only related to Strapi v3@alpha.14.2 ([v1 documentation is still available](http://strapi.io/documentation/1.x.x)).
1919

2020
**[Get Started](getting-started/installation.md)**<br />
2121
Learn how to install Strapi and start developing your API.

docs/3.x.x/concepts/concepts.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ The controllers are defined in each `./api/**/controllers/` folders. Every JavaS
9494

9595
## Filters
9696

97-
Filters are a handy way to request data according to generic parameters. It makes filtering, sorting and paginating easy and reusable (eg. `GET /user?_limit=30&name=John`).
97+
Filters are a handy way to request data according to generic parameters. It makes filtering, sorting and paginating easy and reusable (eg. `GET /users?_limit=30&name=John`).
9898

9999
> Please refer to the [filters' guide](../guides/filters.md) for more informations.
100100

docs/3.x.x/configurations/configurations.md

+64-9
Original file line numberDiff line numberDiff line change
@@ -169,13 +169,8 @@ You can access the config of the current environment through `strapi.config.curr
169169
- `connections` List of all available connections.
170170
- `default`
171171
- `connector` (string): Connector used by the current connection. Default value: `strapi-hook-mongoose`.
172-
- `client` (string): Client used to store session. Default value: `cookie`.
173-
- `key` (string): Cookie key name. Default value: `strapi.sid`
174-
- `maxAge` (integer): Time in milliseconds before the session expire. Default value: `86400000`.
175-
- `rolling` (boolean): Force a session identifier cookie to be set on every response. Default value: `false`.
176-
- `signed` (boolean): httpOnly or not. Default value: `true`.
177-
- `overwrite` (boolean): Can overwrite or not. Default value: `true`.
178172
- `settings` Useful for external session stores such as Redis.
173+
- `client` (string): Database client to create the connection. Default value: `mongo`.
179174
- `host` (string): Database host name. Default value: `localhost`.
180175
- `port` (integer): Database port. Default value: `27017`.
181176
- `database` (string): Database name. Default value: `development`.
@@ -255,6 +250,33 @@ You can access the config of the current environment through `strapi.config.curr
255250

256251
> Please refer to the [dynamic configurations section](#dynamic-configurations) to use global environment variable to configure the databases.
257252
253+
#### MLab Example
254+
255+
**Path —** `./config/environments/**/database.json`.
256+
```json
257+
{
258+
"defaultConnection": "default",
259+
"connections": {
260+
"default": {
261+
"connector": "strapi-hook-mongoose",
262+
"settings": {
263+
"client": "mongo",
264+
"host": "ds123456.mlab.com",
265+
"port": 12345,
266+
"database": "mlab_db_name",
267+
"username": "mlab_user_name",
268+
"password": "mlab_pass"
269+
},
270+
"options": {
271+
"authenticationDatabase": "mlab_db_name",
272+
"ssl": false
273+
}
274+
}
275+
}
276+
}
277+
```
278+
279+
> Please note that you must give your MLab database name as the authenticationDatabase and your password can not contain the "@" symbol.
258280
259281

260282

@@ -279,8 +301,6 @@ You can access the config of the current environment through `strapi.config.curr
279301
- `parser`
280302
- `enabled`(boolean): Enable or disable parser. Default value: `true`.
281303
- `multipart` (boolean): Enable or disable multipart bodies parsing. Default value: `true`.
282-
- `router`
283-
- `prefix` (string): API url prefix (eg. `/v1`).
284304

285305
::: note
286306
The session doesn't work with `mongo` as a client. The package that we should use is broken for now.
@@ -341,10 +361,18 @@ The session doesn't work with `mongo` as a client. The package that we should us
341361

342362
- `host` (string): Host name. Default value: `localhost`.
343363
- `port` (integer): Port on which the server should be running. Default value: `1337`.
344-
- `autoReload` (boolean): Enable or disabled server reload on files update. Default value: depends on the environment.
364+
- `autoReload`
365+
- `enabled` (boolean): Enable or disabled server reload on files update. Default value: depends on the environment.
366+
- `emitErrors` (boolean): Enable errors to be emited to `koa` when they happen in order to attach custom logic or use error reporting services.
367+
- `proxy`
368+
- `enabled` (boolean): Enable proxy support such as Apache or Nginx. Default value: `false`.
369+
- `ssl` (boolean): Enable proxy SSL support
370+
- `host` (string): Host name your proxy service uses for Strapi.
371+
- `port` (integer): Port that your proxy service accepts connections on.
345372
- [`cron`](https://en.wikipedia.org/wiki/Cron)
346373
- `enabled` (boolean): Enable or disable CRON tasks to schedule jobs at specific dates. Default value: `false`.
347374
- `admin`
375+
- `autoOpen` (boolean): Enable or disabled administration opening on start (default: `true`)
348376
- `path` (string): Allow to change the URL to access the admin (default: `/admin`).
349377
- `build`
350378
- `host` (string): URL to access the admin panel (default: `http://localhost:1337/admin`).
@@ -353,6 +381,33 @@ The session doesn't work with `mongo` as a client. The package that we should us
353381
- `source` (string): Define the source mode (origin, host, custom).
354382
- `folder` (string): Indicate what the plugins folder in `host` source mode.
355383

384+
#### Example
385+
386+
**Path —** `./config/environments/**/server.json`.
387+
388+
As an example using this configuration with Nginx your server would respond to `https://example.com:8443` instead of `http://localhost:1337`
389+
390+
**Note:** you will need to configure Nginx or Apache as a proxy before configuring this example.
391+
392+
```json
393+
{
394+
"host": "localhost",
395+
"port": 1337,
396+
"proxy": {
397+
"enabled": true,
398+
"ssl": true,
399+
"host": "example.com",
400+
"port": 8443
401+
},
402+
"autoReload": {
403+
"enabled": true
404+
},
405+
"cron": {
406+
"enabled": true
407+
}
408+
}
409+
```
410+
356411
***
357412

358413
## Dynamic configurations
875 KB
Loading

docs/3.x.x/getting-started/installation.md

+7-2
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,13 @@ Installation is very easy and only takes a few seconds.
55
## Requirements
66

77
Please make sure your computer/server meets the following requirements:
8-
- [Node.js](https://nodejs.org) >= 9: Node.js is a server platform which runs JavaScript. Installation guide [here](https://nodejs.org/en/download/).
9-
- [MongoDB](https://www.mongodb.com/) >= 2.6: MongoDB is a powerful document store. Installation guide [here](https://www.mongodb.com/download-center?j#community).
8+
- [Node.js](https://nodejs.org) >= 10.x: Node.js is a server platform which runs JavaScript. Installation guide [here](https://nodejs.org/en/download/).
9+
- [NPM](https://www.npmjs.com/) >= 6.x: NPM is the package manager for Javascript. Installation guide [here](https://nodejs.org/en/download/).
10+
*(Make sure the database that you are using meets the requirement.)*
11+
- [MongoDB](https://www.mongodb.com/) >= 3.x: MongoDB is a powerful document store. Installation guide [here](https://www.mongodb.com/download-center?j#community).
12+
- [MySQL](https://www.mysql.com/) >= 5.6: MySQL is an open-source relational database management system. Installation guide [here](https://dev.mysql.com/downloads/).
13+
- [MariaDB](https://mariadb.org/) >= 10.1: MarialDB is a fork of MySQL and is guaranteed to stay open source. Installation guide [here](https://mariadb.org/download/).
14+
- [PostgreSQL](https://www.postgresql.org/) >= 10: PostgreSQL is an open-source object-relational database management system. Installation guide [here](https://www.postgresql.org/download/).
1015

1116
## Setup
1217

docs/3.x.x/getting-started/quick-start.md

+7-7
Original file line numberDiff line numberDiff line change
@@ -136,16 +136,16 @@ In order to do so, you'll need to allow access to other users (identified as 'Gu
136136

137137
### List entries (GET)
138138

139-
To retrieve the list of products, use the `GET /your-content-type` route.
139+
To retrieve the list of products, use the `GET /products` route.
140140

141-
Generated APIs provide a handy way to filter and order queries. In that way, ordering products by price is as easy as `GET http://localhost:1337/product?_sort=price:asc`. For more informations, read the [filters documentation](../guides/filters.md)
141+
Generated APIs provide a handy way to filter and order queries. In that way, ordering products by price is as easy as `GET http://localhost:1337/products?_sort=price:asc`. For more informations, read the [filters documentation](../guides/filters.md)
142142

143143
Here is an example using jQuery.
144144

145145
```js
146146
$.ajax({
147147
type: 'GET',
148-
url: 'http://localhost:1337/product?_sort=price:asc', // Order by price.
148+
url: 'http://localhost:1337/products?_sort=price:asc', // Order by price.
149149
done: function(products) {
150150
console.log('Well done, here is the list of products: ', products);
151151
},
@@ -162,7 +162,7 @@ If you want to get a specific entry, add the `id` of the wanted product at the e
162162
```js
163163
$.ajax({
164164
type: 'GET',
165-
url: 'http://localhost:1337/product/123', // Where `123` is the `id` of the product.
165+
url: 'http://localhost:1337/products/123', // Where `123` is the `id` of the product.
166166
done: function(product) {
167167
console.log('Well done, here is the product having the `id` 123: ', product);
168168
},
@@ -181,7 +181,7 @@ jQuery example:
181181
```js
182182
$.ajax({
183183
type: 'POST',
184-
url: 'http://localhost:1337/product',
184+
url: 'http://localhost:1337/products',
185185
data: {
186186
name: 'Cheese cake',
187187
description: 'Chocolate cheese cake with ice cream',
@@ -205,7 +205,7 @@ jQuery example:
205205
```js
206206
$.ajax({
207207
type: 'PUT',
208-
url: 'http://localhost:1337/product/123', // Where `123` is the `id` of the product.
208+
url: 'http://localhost:1337/products/123', // Where `123` is the `id` of the product.
209209
data: {
210210
description: 'This is the new description'
211211
},
@@ -227,7 +227,7 @@ jQuery example:
227227
```js
228228
$.ajax({
229229
type: 'DELETE',
230-
url: 'http://localhost:1337/product/123', // Where `123` is the `id` of the product.
230+
url: 'http://localhost:1337/products/123', // Where `123` is the `id` of the product.
231231
done: function(product) {
232232
console.log('Congrats, your product has been successfully deleted: ', product);
233233
},

0 commit comments

Comments
 (0)