A Q&A platform software for teams at any scales. Whether it's a community forum, help center, or knowledge management platform, you can always count on Apache Answer.
feat: add html text cut pkg
LinkinStar8ac92750a41b
diff --git a/pkg/htmltext/htmltext.go b/pkg/htmltext/htmltext.goindex e2acb315..31ae1a22 100644--- a/pkg/htmltext/htmltext.go+++ b/pkg/htmltext/htmltext.go@@ -1,10 +1,9 @@package htmltextimport (+ "github.com/grokify/html-strip-tags-go""regexp""strings"-- "github.com/grokify/html-strip-tags-go")// ClearText clear HTML, get the clear textdiff --git a/pkg/htmltext/htmltext_test.go b/pkg/htmltext/htmltext_test.goindex 568299af..71aafbb6 100644--- a/pkg/htmltext/htmltext_test.go+++ b/pkg/htmltext/htmltext_test.go@@ -1,9 +1,8 @@package htmltextimport (- "testing"-"github.com/stretchr/testify/assert"+ "testing")func TestClearText(t *testing.T) {