Good practice to include javascript functions in view?

I was just wondering if it was good pratice to have a load of javascript functions in a view file, or whether these javascript functions should be put in a javascript file and loaded in.

Static assets should be served as static assets. It makes sense to have a script tag (e.g. javascript_tag) in your views, and maybe an occasional and very small script tag with inline code that uses functions/objects in your static JS files. If you find yourself writing more than three or so lines of JS in a view, you should probably pull it out into a static JS file.

Thanks for your time.

--Greg