0

After using $.getScript to get some javascript I now want to remove this script. How can this be done.

1 Answer 1

3

You cannot remove a script that has already been loaded. There's no such concept. You will have to adapt this script so that it behaves as you expect it to depending on some runtime conditions. So for example if this script executes some action, you will have to modify this script so that it executes this action based on some conditions you specify. This way you can control how this script behaves.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.