<commit_before># Proxy To Backend

Using the [proxying support](https://webpack.js.org/configuration/dev-server/#devserver-proxy) in webpack's dev server we can highjack certain URLs and send them to a backend server.
We do this by passing a file to `--proxy-config`

Say we have a server running on `http://localhost:3000/api` and we want all calls to `http://localhost:4200/api` to go to that server.

We create a file next to our project's `package.json` called `proxy.conf.json` with the content

```json
{
  "/api": {
    "target": "http://localhost:3000",
    "secure": false
  }
}
```

You can read more about what options are available [here](https://webpack.js.org/configuration/dev-server/#devserver-proxy).

We can then add the `proxyConfig` option to the serve target:

```json
"architect": {
  "serve": {
    "builder": "@angular-devkit/build-angular:dev-server",
    "options": {
      "browserTarget": "your-application-name:build",
      "proxyConfig": "src/proxy.conf.json"
    },
```

Now in order to run our dev server with our proxy config we can call `ng serve`.

**After each edit to the proxy.conf.json file remember to relaunch the `ng serve` process to make your changes effective.**

### Rewriting the URL path<commit_msg>docs: updated proxyConfig property folder path<commit_after># Proxy To Backend

Using the [proxying support](https://webpack.js.org/configuration/dev-server/#devserver-proxy) in webpack's dev server we can highjack certain URLs and send them to a backend server.
We do this by passing a file to `--proxy-config`

Say we have a server running on `http://localhost:3000/api` and we want all calls to `http://localhost:4200/api` to go to that server.

We create a file next to our project's `package.json` called `proxy.conf.json` with the content

```json
{
  "/api": {
    "target": "http://localhost:3000",
    "secure": false
  }
}
```

You can read more about what options are available [here](https://webpack.js.org/configuration/dev-server/#devserver-proxy).

We can then add the `proxyConfig` option to the serve target:

```json
"architect": {
  "serve": {
    "builder": "@angular-devkit/build-angular:dev-server",
    "options": {
      "browserTarget": "your-application-name:build",
      "proxyConfig": "proxy.conf.json"
    },
```

Now in order to run our dev server with our proxy config we can call `ng serve`.

**After each edit to the proxy.conf.json file remember to relaunch the `ng serve` process to make your changes effective.**

### Rewriting the URL path
{'fraction_non_alphanumeric': 0.12594059405940594, 'fraction_numerical': 0.009504950495049505, 'mean_word_length': 3.9822485207100593, 'pattern_counts': {'":': 18, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 4, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5431650', 'n_tokens_mistral': 778, 'n_tokens_neox': 743, 'n_words': 292}