Home
Docs
GitHub
Pricing
Blog
Log In

Run Sandworm Audit for your App

Get started
Generated on Jun 1, 2024 via composer

sonata-project/block-bundle 5.1.0

Symfony SonataBlockBundle
Package summary
Share
0
issues
2
licenses
51
MIT
1
BSD-3-Clause
Package created
6 Mar 2012
Version published
23 Nov 2023
Maintainers
1
Total deps
52
Direct deps
20
License
MIT

Issues

0
This package has no issues

Licenses

MIT License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
sublicense
private-use
Cannot
hold-liable
Must
include-copyright
include-license
51 Packages, Including:
doctrine/collections@2.2.2
doctrine/common@3.4.4
doctrine/deprecations@1.1.3
doctrine/event-manager@2.0.1
doctrine/persistence@3.3.2
psr/cache@3.0.0
psr/container@2.0.2
psr/event-dispatcher@1.0.0
psr/log@3.0.0
sonata-project/block-bundle@5.1.0
sonata-project/form-extensions@2.4.0
symfony/asset@v7.1.0
symfony/cache@v7.1.0
symfony/cache-contracts@v3.5.0
symfony/config@v7.1.0
symfony/console@v7.1.0
symfony/dependency-injection@v7.1.0
symfony/deprecation-contracts@v3.5.0
symfony/error-handler@v7.1.0
symfony/event-dispatcher@v7.1.0
symfony/event-dispatcher-contracts@v3.5.0
symfony/filesystem@v7.1.0
symfony/finder@v7.1.0
symfony/form@v7.1.0
symfony/framework-bundle@v7.1.0
symfony/http-foundation@v7.1.0
symfony/http-kernel@v7.1.0
symfony/options-resolver@v7.1.0
symfony/password-hasher@v7.1.0
symfony/polyfill-ctype@v1.29.0
symfony/polyfill-intl-grapheme@v1.29.0
symfony/polyfill-intl-icu@v1.29.0
symfony/polyfill-intl-normalizer@v1.29.0
symfony/polyfill-mbstring@v1.29.0
symfony/polyfill-php80@v1.29.0
symfony/polyfill-php83@v1.29.0
symfony/property-access@v7.1.0
symfony/property-info@v7.1.0
symfony/routing@v7.1.0
symfony/security-core@v7.1.0
symfony/security-csrf@v7.1.0
symfony/service-contracts@v3.5.0
symfony/string@v7.1.0
symfony/translation@v7.1.0
symfony/translation-contracts@v3.5.0
symfony/twig-bridge@v7.1.0
symfony/twig-bundle@v7.1.0
symfony/type-info@v7.1.0
symfony/validator@v7.1.0
symfony/var-dumper@v7.1.0

BSD 3-Clause "New" or "Revised" License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
place-warranty
Cannot
use-trademark
hold-liable
Must
include-copyright
include-license
1 Packages, Including:
twig/twig@v3.10.3
Disclaimer

This deed highlights only some of the key features and terms of the actual license. It is not a license and has no legal value. You should carefully review all of the terms and conditions of the actual license before using the licensed material.

Sandworm is not a law firm and does not provide legal services. Distributing, displaying, or linking to this deed or the license that it summarizes does not create a lawyer-client or any other relationship.

Direct Dependencies

20
All Dependencies CSV
β“˜ This is a list of sonata-project/block-bundle 's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
NameVersionSizeLicenseTypeVulnerabilities
doctrine/collections2.2.2-MIT
prod dev
doctrine/common3.4.4-MIT
prod dev
psr/container2.0.23.55 kBMIT
prod dev
psr/log3.0.06.77 kBMIT
prod dev
sonata-project/form-extensions2.4.0-MIT
prod
symfony/assetv7.1.0-MIT
prod dev
symfony/configv7.1.0-MIT
prod dev
symfony/consolev7.1.0-MIT
prod dev
symfony/dependency-injectionv7.1.0-MIT
prod dev
symfony/error-handlerv7.1.0-MIT
prod dev
symfony/event-dispatcherv7.1.0-MIT
prod dev
symfony/event-dispatcher-contractsv3.5.0-MIT
prod dev
symfony/formv7.1.0-MIT
prod dev
symfony/framework-bundlev7.1.0-MIT
prod dev
symfony/http-foundationv7.1.0-MIT
prod dev
symfony/http-kernelv7.1.0-MIT
prod dev
symfony/options-resolverv7.1.0-MIT
prod
symfony/twig-bundlev7.1.0-MIT
prod dev
symfony/validatorv7.1.0-MIT
prod dev
twig/twigv3.10.3-BSD-3-Clause
prod dev

Visualizations

Frequently Asked Questions

What does sonata-project/block-bundle do?

The Sonata Block Bundle is a highly useful component of the Sonata Project, specifically designed for the Symfony framework. This bundle enables users to manage blocks, a crucial feature in web applications for handling sections of a web page. By leveraging the power of the Sonata Block Bundle, web developers can efficiently manage and customize the website's structure, including the banner, footer, sidebar, and other parts of a web page, simplifying the overall website development process.

How do you use sonata-project/block-bundle?

Usage of the Sonata Block Bundle first requires installation. The most common way to add this beneficial bundle to your Symfony project is by using Composer, a tool for dependency management in PHP. To install the Sonata Block Bundle, run composer require sonata-project/block-bundle in your project terminal.

The official and practical usage instructions can be found in the documentation, but practically, it's about defining 'blocks' in your Symfony application that represent different parts of your site.

For instance, you can define a block as follows:

namespace App\Block;

use Sonata\BlockBundle\Block\Service\AbstractBlockService;
use Sonata\BlockBundle\Block\BlockContextInterface;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\OptionsResolver\OptionsResolver;
use Twig\Environment;

class MyCustomBlock extends AbstractBlockService
{
   public function configureOptions(OptionsResolver $resolver)
   {
       $resolver->setDefaults(array(
           'template' => 'blocks/my_custom_block.html.twig',
       ));
   }

   public function execute(BlockContextInterface $blockContext, Response $response = null)
   {
       // render the block
       return $this->renderResponse($blockContext->getTemplate(), array(
           'block'     => $blockContext->getBlock(),
           'settings'  => $blockContext->getSettings()
       ), $response);
   }
}

This code defines a new block with a related Twig template. This block can then be rendered in any Symfony controller or Twig template.

Where are the sonata-project/block-bundle docs?

For further information and document reference, the comprehensive documentation of Sonata Block Bundle is hosted on the official Sonata Project website. The documentation provides a step-by-step guide to effectively utilize the bundle, including installation, configuration, and other common functionalities. Visit SonataBlockBundle documentation for a detailed explanation and various examples on how to maximize the potential of this bundle in your Symfony project.