Web Dev Trends
21 subscribers
697 photos
6 videos
690 links
Полезные статьи и новости веб разработки
Download Telegram
#laravel #php #tips #json

Laravel Tip💡: Assert JSON Fragments

When testing APIs, we often need to check if the response contains a specific key with the expected data. Laravel ships with the assertJsonFragment to do exactly that 🚀

@webdev_trends
#larvel #php #tips #backend #webdev

Ever wondered what is the difference between the register and boot method on the Laravel Service Providers and also when to use which method? Here is a series that I have tried to explain the best I can.

@webdev_trends
#laravel #php #tips #backend #webdev

Don't let database queries slow you down. Use Laravel's cache facade to cache data temporarily, reducing database queries.

@webdev_trends
#js #JavaScript #webdev

Understanding the Console Object in JavaScript.

The console object in JavaScript is a powerful tool for debugging and logging. It offers a variety of methods that go beyond simple logging, providing developers with a comprehensive toolkit for monitoring, analyzing, and debugging their code. This article explores all 25 methods provided by the console object, detailing their usage and applications.

👉 Read article 👈

@webdev_trends
#js #JavaScript #frontend #webdev

The "boolean" function in JavaScript lets you convert any value into either "true" or "false". This can be useful when dealing with TypeScript, outputting JSON, or using it with the "filter" method.

👉 Watch video 👈

@webdev_trends
#css #frontend #webdev

Grid is awesome, and there are some neat tricks that you can do with it that I don’t see enough people taking advantage of, like overlapping named grid lines, using position absolute with grid, and animating template-rows and template-columns.

👉 Watch video 👈

@webdev_trends
#laravel #php #tips #webdev

Check out this awesome article on clean code tips!📝

Learn how to use scopes to get rid of those long code blocks and keep your code neat!

👉 Watch video

@webdev_trends
#beginners #docker #devops #tutorial

1. Running our First Docker Image

In the recent years, technological improvements across all industries have dramatically increased the rate at which software products are demanded and consumed. Trends like agile development and continuous integration also increased demand. As a result, many organizations have opted to switch to cloud infrastructure.

👉 Read article

@webdev_trends
👍1
#beginners #docker #devops #tutorial

2. Basic Container Lifecycle Management

Throughout your container journey, you will be pulling, starting, stopping, and removing containers from your local environment quite frequently. Prior to deploying a container in a production environment, it is critical to run the container locally to understand how it should work. This includes starting, stopping and restarting containers, getting details about how the container is running, and, of course accessing verbose logs to view critical details about the applications running inside the container.

👉 Read article

@webdev_trends
👍1
#beginners #docker #devops #tutorial

3. Getting Started with Dockerfiles

In the previous posts, we discussed how you can run your first Docker container by pulling pre-built Docker images from Docker Hub. While it is useful to get pre-built Docker images from Docker Hub, we can't only rely on them. This is important for running our applications on Docker by installing new packages and customizing the settings of the pre-built Docker images.

This will be done using a text file called a Dockerfile. This file consists of commands that can be executed by Docker to create a docker image. Docker images are created from a Dockerfile using the docker build or docker image build command.

👉 Read article

@webdev_trends
👍1
#beginners #docker #devops #tutorial

4. Attaching To Containers Using the Attach Command

In the previous post, we discussed how to use the docker exec command to spin up a new shell session in a running container instance. The docker exec command is very useful for quickly gaining access to a containerized instance for debugging, troubleshooting, and understanding the context the container is running in.

However, Docker containers run as per the life of the primary process running inside the container. When this process exits, the container will stop. If you need to access the primary process inside the container directly (as opposed to a secondary shell session), then you can use the docker attach command to attach to the primary running process inside the container.

👉 Read article

@webdev_trends
👍1
#beginners #docker #devops #tutorial

5. Building Docker Images


In the previous post we discussed how to create a Dockerfile. The next step of the process is to build a Docker image using the Dockerfile.

A Docker image is like a compiled file. It's built in layers, starting with the base layer that contains the fundamental setup. This is usually the layer we use the FROM directive. Each subsequent layer adds on top of the previous one, making small adjustments or additions. These layers are stacked on top of another, and each layer builds up the changes made in the layer before it.

👉 Read article

@webdev_trends
👍1
#beginners #docker #devops #tutorial

6. Advanced
Dockerfile Directives

In this post, we are going to discuss more advanced Dockerfile directives. These directives can be used to create more advanced Docker images.

For example, we can use the VOLUME directive to bind the filesystem of the host machine to a Docker container. This will allow us to save the data generated and used by the Docker container to our local machine.

👉 Read article

@webdev_trends
👍1