Skip to content

Commit e4b2d71

Browse files
authored
Release 4.0.0
1 parent 649e9da commit e4b2d71

32 files changed

+299
-550
lines changed

.gitignore

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
vendor/
2-
composer.lock
1+
/vendor
2+
/composer.lock

.scrutinizer.yml

Lines changed: 17 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,28 @@
11
filter:
22
excluded_paths:
3+
- tests/*
34
- vendor/*
4-
- Tests/*
55

66
checks:
77
php:
88
code_rating: true
99
duplication: true
1010

1111
build:
12-
tests:
12+
environment:
13+
redis: false
14+
docker: true
15+
16+
dependencies:
1317
override:
14-
-
15-
command: ./vendor/bin/phpunit --coverage-clover ./clover.xml
16-
coverage:
17-
file: clover.xml
18-
format: clover
18+
- docker-compose up -d --remove-orphans --build
19+
- docker-compose exec -T php /usr/local/bin/php /usr/local/bin/composer install
20+
21+
nodes:
22+
coverage:
23+
tests:
24+
override:
25+
- command: docker-compose run --rm -T php /usr/local/bin/php /app/vendor/bin/phpunit --coverage-clover=coverage.xml
26+
coverage:
27+
file: coverage.xml
28+
format: clover

.sensiolabs.yml

Lines changed: 0 additions & 6 deletions
This file was deleted.

.travis.yml

Lines changed: 0 additions & 27 deletions
This file was deleted.

DependencyInjection/Configuration.php

Lines changed: 0 additions & 42 deletions
This file was deleted.

DependencyInjection/JsonRequestExtension.php

Lines changed: 0 additions & 34 deletions
This file was deleted.

Dockerfile

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
FROM php:7.4-fpm-alpine
2+
3+
ENV COMPOSER_ALLOW_SUPERUSER 1
4+
5+
RUN apk add git build-base php7-dev && \
6+
pecl -q install xdebug && \
7+
docker-php-ext-enable xdebug && \
8+
curl -s https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer
9+
10+
WORKDIR /app

EventListener/RequestListenerInterface.php

Lines changed: 0 additions & 13 deletions
This file was deleted.

EventListener/RequestTransformerListener.php

Lines changed: 0 additions & 58 deletions
This file was deleted.

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
The MIT License (MIT)
22

3-
Copyright (c) 2016-2017 Symfony Bundles (Dmitry Khaperets)
3+
Copyright (c) 2016-2021 Dmitry Khaperets
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

Makefile

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
phpunit:
2+
docker-compose run --rm -T php /usr/local/bin/php /app/vendor/bin/phpunit
3+
4+
phpstan:
5+
docker-compose run --rm -T php /usr/local/bin/php /app/vendor/bin/phpstan analyse
6+
7+
coverage:
8+
docker-compose run --rm -T php /usr/local/bin/php /app/vendor/bin/phpunit --coverage-html=vendor/coverage
9+
10+
composer-update:
11+
docker-compose run --rm -T php /usr/local/bin/php /usr/local/bin/composer update

README.md

Lines changed: 17 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,29 @@
1-
SymfonyBundles JsonRequest Bundle
2-
=================================
1+
Symfony JsonRequest Bundle
2+
==========================
33

4-
[![SensioLabsInsight][sensiolabs-insight-image]][sensiolabs-insight-link]
5-
6-
[![Build Status][testing-image]][testing-link]
74
[![Scrutinizer Code Quality][scrutinizer-code-quality-image]][scrutinizer-code-quality-link]
85
[![Code Coverage][code-coverage-image]][code-coverage-link]
96
[![Total Downloads][downloads-image]][package-link]
107
[![Latest Stable Version][stable-image]][package-link]
118
[![License][license-image]][license-link]
129

10+
Installation
11+
------------
12+
13+
* Require the bundle with composer:
14+
15+
``` bash
16+
composer req symfony-bundles/json-request-bundle
17+
```
18+
1319
What is JsonRequest Bundle?
1420
---------------------------
15-
This bundle will help you to work with json requests as standard requests without using «crutches».
16-
If previously for fetching of data from the request you did like this:
17-
`$data = json_decode($request->getContent())`,
18-
it is now in this already there is no need to.
21+
This bundle will help you to work with json requests as standard requests without using «crutches». If previously for
22+
fetching of data from the request you did like this:
23+
`$data = json_decode($request->getContent())`, it is now in this already there is no need to.
24+
25+
For example when sending json-request from AngularJS, Vue.js or etc. Early:
1926

20-
For example when sending json-request from AngularJS, Vue.js or etc.
21-
Early:
2227
``` php
2328
public function indexAction(Request $request)
2429
{
@@ -30,30 +35,19 @@ public function indexAction(Request $request)
3035
```
3136

3237
Now you can work with json-request as with standard request:
38+
3339
``` php
3440
public function indexAction(Request $request)
3541
{
3642
$name = $request->get('name');
3743
}
3844
```
3945

40-
Installation
41-
------------
42-
* Require the bundle with composer:
43-
44-
``` bash
45-
composer require symfony-bundles/json-request-bundle
46-
```
47-
4846
[package-link]: https://packagist.org/packages/symfony-bundles/json-request-bundle
4947
[license-link]: https://github.com/symfony-bundles/json-request-bundle/blob/master/LICENSE
5048
[license-image]: https://poser.pugx.org/symfony-bundles/json-request-bundle/license
51-
[testing-link]: https://travis-ci.org/symfony-bundles/json-request-bundle
52-
[testing-image]: https://travis-ci.org/symfony-bundles/json-request-bundle.svg?branch=master
5349
[stable-image]: https://poser.pugx.org/symfony-bundles/json-request-bundle/v/stable
5450
[downloads-image]: https://poser.pugx.org/symfony-bundles/json-request-bundle/downloads
55-
[sensiolabs-insight-link]: https://insight.sensiolabs.com/projects/dea68633-2368-4e12-a516-89157d2c6b07
56-
[sensiolabs-insight-image]: https://insight.sensiolabs.com/projects/dea68633-2368-4e12-a516-89157d2c6b07/big.png
5751
[code-coverage-link]: https://scrutinizer-ci.com/g/symfony-bundles/json-request-bundle/?branch=master
5852
[code-coverage-image]: https://scrutinizer-ci.com/g/symfony-bundles/json-request-bundle/badges/coverage.png?b=master
5953
[scrutinizer-code-quality-link]: https://scrutinizer-ci.com/g/symfony-bundles/json-request-bundle/?branch=master

SymfonyBundlesJsonRequestBundle.php

Lines changed: 0 additions & 16 deletions
This file was deleted.

Tests/DependencyInjection/ConfigurationTest.php

Lines changed: 0 additions & 23 deletions
This file was deleted.

0 commit comments

Comments
 (0)