{"id":16181728,"url":"https://github.com/ericclemmons/grunt-livereload","last_synced_at":"2025-04-07T12:25:06.803Z","repository":{"id":6525686,"uuid":"7766690","full_name":"ericclemmons/grunt-livereload","owner":"ericclemmons","description":"[DEPRECATED] Refresh your CSS (or page) with each save via LiveReload","archived":false,"fork":false,"pushed_at":"2013-02-24T21:21:49.000Z","size":138,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-06T07:15:41.570Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://github.com/gruntjs/grunt-contrib-livereload","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ericclemmons.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-01-23T03:07:06.000Z","updated_at":"2013-10-03T22:59:00.000Z","dependencies_parsed_at":"2022-09-08T02:34:53.921Z","dependency_job_id":null,"html_url":"https://github.com/ericclemmons/grunt-livereload","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ericclemmons%2Fgrunt-livereload","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ericclemmons%2Fgrunt-livereload/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ericclemmons%2Fgrunt-livereload/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ericclemmons%2Fgrunt-livereload/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ericclemmons","download_url":"https://codeload.github.com/ericclemmons/grunt-livereload/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247650444,"owners_count":20973275,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-10T06:26:57.476Z","updated_at":"2025-04-07T12:25:06.779Z","avatar_url":"https://github.com/ericclemmons.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# grunt-livereload\n\nRefresh your CSS (or page) with each save via [LiveReload][1].\n\n## DEPRECATED IN FAVOR OF `grunt-contrib-livereload`\n\n\u003e https://github.com/gruntjs/grunt-contrib-livereload\n\nThis plugin originated by there not being a LiveReload plugin that could be reloaded via `watch` repeatedly that also supported CSS-only reloading.\n\nNow that the Yeoman community has resolved that, this plugin is no longer necessary, even though it still works great :)\n\n\n## Getting Started\n\nFirst, install this grunt plugin next to your project's [grunt.js gruntfile][getting_started] with: `npm install grunt-livereload`\n\nSecond, add this line to your project's `grunt.js` gruntfile:\n\n```javascript\ngrunt.loadNpmTasks('grunt-livereload');\n```\n\n\n## Documentation\n\nThird, have livereload monitor changes to **browser-accessible resources**.\nThis part is crucial, as CSS, if specified correctly, can be reloaded without\nrefreshing the entire page.\n\n```javascript\n// grunt.js\n{\n  ...\n  livereload  : {\n    options   : {\n      base    : 'public',\n    },\n    files     : ['public/**/*']\n  }\n  ...\n}\n```\n\nIn this example, `public/css/app.css` will trigger a reload of the `css/app.css` resource only,\nwhile `public/index.html` will cause a full page refresh.\n\nFinally, ensure your `watch` task doesn't process CSS at the same time it\nprocesses HTML, JS, and other resources that are being monitored:\n\n```javascript\n// grunt.js\n{\n  watch: {\n    somecss: {\n      files: '**/*.css',\n      tasks: ['copy:somecss']\n    },\n    js: {\n      files: '**/*.js',\n      tasks: ['concat']\n    }\n  }\n}\n```\n\nMany people watch *everything* and run their build process each time.  This\nis unecessarily slow and prevents LiveReload from being able to see when\n*only the `.css` has changed*.  So, it's recommended that you watch different\n*types* of files and perform only what's necessary to rebuild those.\n\nThis way, CSS is copied/processed alone and LiveReload will seamlessly replace\nthe styles in your page without refreshing the whole browser.\n\n[grunt]: http://gruntjs.com/\n[getting_started]: https://github.com/gruntjs/grunt/blob/master/docs/getting_started.md\n\n\n## Changelog\n\n### v0.1.3\n\n- Grunt 0.4 support (Thanks [@xbudex](https://github.com/ericclemmons/grunt-livereload/pull/2)!)\n\n\n### v0.1.2\n\n- If `livereload` attempts to start an already-running server, it logs\n  to the console rather than throwing an `err`.  (This is common when\n  clearing `require.cache`)\n\n### v0.1.1\n\n- Refresh browser when `livereload` task is ran while server is running\n\n### v0.1.0\n\n- Initial release\n\n\n## License\n\nCopyright (c) 2013 Eric Clemmons\nLicensed under the MIT license.\n\n\n[1]: http://feedback.livereload.com/knowledgebase/articles/86242-how-do-i-install-and-use-the-browser-extensions-\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fericclemmons%2Fgrunt-livereload","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fericclemmons%2Fgrunt-livereload","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fericclemmons%2Fgrunt-livereload/lists"}