Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

js notifications

//toastr Sweet Alert
//css
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/toastr.js/latest/toastr.css" integrity="sha512-3pIirOrwegjM6erE5gPSwkUzO+3cTjpnV9lexlNZqvupR64iZBnOOTiiLPb9M36zpMScbmUNIcHUqKD47M719g==" crossorigin="anonymous" referrerpolicy="no-referrer" />

//must have
var Toast = Swal.mixin({
    toast: true,
    position: 'top-end',
    showConfirmButton: false,
    timer: 3000
});

//how to use toastr:
Toast.fire({
    icon: 'success', // error, info, warning
    title: 'Successfully Created.'
})
//or
toastr.success('Successfully Created.') // error, info, warning

//js
<script src="//cdn.jsdelivr.net/npm/sweetalert2@11"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/toastr.js/latest/toastr.min.js" integrity="sha512-VEd+nq25CkR676O+pLBnDW09R7VQX9Mdiij052gVCp5yVH3jGtH70Ho/UUv4mJDsEdTvqRCFZg0NKGiojGnUCw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
Comment

PREVIOUS NEXT
Code Example
Javascript :: downgrade nodejs with nvm 
Javascript :: js null is object typeof 
Javascript :: angular passing data to child component 
Javascript :: javascript splice without changing array 
Javascript :: set _id to id 
Javascript :: chrome.storage.local get 
Javascript :: string to json nodejs 
Javascript :: .filter js 
Javascript :: get count of class which is visible element 
Javascript :: Execute JavaScript using Selenium WebDriver in C# 
Javascript :: disable javascript chrome 
Javascript :: javascript pseudo random 
Javascript :: tinymce update textarea value using jquery 
Javascript :: install vue js 
Javascript :: mssql node js documentation 
Javascript :: $q.platform.is.mobile 
Javascript :: how to get selected value of a dropdown menu in reactjs 
Javascript :: formdata append not working 
Javascript :: @babel/plugin-proposal-optional-chaining 
Javascript :: require a json as a string 
Javascript :: angular jspdf 
Javascript :: javascript loop object 
Javascript :: javascript change background color setinterval 
Javascript :: change localhost react 
Javascript :: js get file location 
Javascript :: delete all objects in array of objects with specific attribute 
Javascript :: reset select option jquery 
Javascript :: pass parameter to handleclick react 
Javascript :: how to return a factorial in javascript 
Javascript :: javascript datetime format 
ADD CONTENT
Topic
Content
Source link
Name
2+9 =