Skip to content

Unable to provide Class AND alt attributes together #153

@onsidelive

Description

@onsidelive

It is not possible to provide class and alt attributes because one overwrites the other

Steps to replicate

  • laravel new laravel-cloudinary
  • cd laravel-cloudinary
  • composer require cloudinary-labs/cloudinary-laravel
  • php artisan cloudinary:install
  • nano .env
CLOUDINARY_URL=cloudinary://API_KEY:API_SECRET@CLOUD_NAME
CLOUDINARY_UPLOAD_PRESET=your_upload_preset
CLOUDINARY_NOTIFICATION_URL=
  • nano config/filesystems.php
 ...,
  'cloudinary' => [
      'driver' => 'cloudinary',
      'key' => env('CLOUDINARY_KEY'),
      'secret' => env('CLOUDINARY_SECRET'),
      'cloud' => env('CLOUDINARY_CLOUD_NAME'),
      'url' => env('CLOUDINARY_URL'),
      'secure' => (bool) env('CLOUDINARY_SECURE', true),
      'prefix' => env('CLOUDINARY_PREFIX'),
  ],
...,
  • composer run dev
  • Edit the default homepage resources/views/welcome.blade.php
  • Insert the image blade component syntax
<x-cloudinary::image public-id="Bpwm1QHtO2R9vkB8A5AvgcpkW2VnLEGb1xxzbTtM" class="img-fluid" alt="Parallax Background Image"/>

Expected Result

The front end homepage will display an image with both the class and alt attributes as they been provided

Actual result

Only the class attribute is provided

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions