Simple search using AngularJS

Size
1,802 Kb
Views
14,168

How do I make an simple search using angularjs?

Ng-repeat+ng-model, i've updated with a single letter search, only the first names will be displayed.. What is a simple search using angularjs? How do you make a simple search using angularjs? This script and codes were developed by Hélio Marcondes on 09 November 2022, Wednesday.

Simple search using AngularJS Previews

Simple search using AngularJS - Script Codes HTML Codes

<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>Simple search using AngularJS</title>
</head>
<body> <body ng-app>
<div ng-controller="List"> <ul> <li ng-repeat="name in names | filter: filterSearch">{{name}}</li> </ul>
</div> <div> <input type="search" ng-model="search"> </div>
</body> <script src='http://ajax.googleapis.com/ajax/libs/angularjs/1.3.2/angular.min.js'></script> <script src="js/index.js"></script>
</body>
</html>

Simple search using AngularJS - Script Codes JS Codes

var List = function($scope){ $scope.names=["Tax", "Tom", "Ralf", "Jerry", "Snow", "Carl"]; function excluirRegex(string){ //Exclude this pattern from search return string.replace(/([.*+?^=!:${}()|\[\]\/\\])/g);
} $scope.filterSearch = function(name) { if (!$scope.search){ return true; }else var regex = new RegExp('\\b' + excluirRegex($scope.search), 'i'); return regex.test(name.split(' ')[0]); }; }
Simple search using AngularJS - Script Codes
Simple search using AngularJS - Script Codes
Home Page Home
Developer Hélio Marcondes
Username haykou
Uploaded November 09, 2022
Rating 3
Size 1,802 Kb
Views 14,168
Do you need developer help for Simple search using AngularJS?

Find the perfect freelance services for your business! Fiverr's mission is to change how the world works together. Fiverr connects businesses with freelancers offering digital services in 500+ categories. Find Developer!

Hélio Marcondes (haykou) Script Codes
Create amazing Facebook ads with AI!

Jasper is the AI Content Generator that helps you and your team break through creative blocks to create amazing, original content 10X faster. Discover all the ways the Jasper AI Content Platform can help streamline your creative workflows. Start For Free!